Calculate thermal time using cardinal temperatures
thermalTime(weather, x_temp, y_temp, method = NULL)
A data.frame with three columns: year, day and thermalTime.
met_file <- system.file("extdata/WeatherRecordsDemo1.met", package = "weaana")
records <- readWeatherRecords(met_file)
x_temp <- c(0, 26, 34)
y_temp <- c(0, 26, 0)
res <- thermalTime(records, x_temp, y_temp)
head(res)
#> year day thermalTime
#> 1 1981 1 19.5500
#> 2 1981 2 20.8000
#> 3 1981 3 23.8875
#> 4 1981 4 22.6500
#> 5 1981 5 25.3000
#> 6 1981 6 24.0000
res <- thermalTime(records, x_temp, y_temp, method = "3hr")
head(res)
#> year day thermalTime
#> 1 1981 1 19.55000
#> 2 1981 2 17.77214
#> 3 1981 3 14.70688
#> 4 1981 4 21.76661
#> 5 1981 5 21.36310
#> 6 1981 6 19.09683