Learn R Programming

weaana (version 0.1.1)

thermalTimeHourly: Calculate thermal time using the hourly temperature (non daily temperature)

Description

Calculate thermal time using the hourly temperature (non daily temperature)

Usage

thermalTimeHourly(timestamp, temperature, x_temp, y_temp)

Arguments

timestamp

The timestamp of weather records

temperature

The temperature

x_temp

The cardinal temperatures

y_temp

The effective thermal time

Value

A data frame with daily thermal time

Examples

Run this code
# NOT RUN {
met_file <- system.file("extdata/WeatherHourly.csv", package = "weaana")
hourly <- read.csv(met_file, as.is = TRUE) 

hourly$timestamp <- as.POSIXct(hourly$timestamp, format = "%Y-%m-%dT%H:%M:%SZ")
x_temp <- c(0, 20, 35)
y_temp <- c(0, 20, 0)
thermalTimeHourly(hourly$timestamp, hourly$temperature, x_temp, y_temp)
# }

Run the code above in your browser using DataLab