Description Usage Arguments Details References Examples
degree_days
returns a data frame with calculated daily degree days within a specified thresholds.
1 | degree_days(data, thresholds)
|
data |
data in wide format with minimum temperature labeled as tmin and maximum temperature labeled as tmax |
thresholds |
threshold of temperature intervals to calculate degree days |
To generate degree days the data must be in wide format with minimum temperature column labeled as tmin and maximum temperature labeled as tmax.
Degree days are calcuated from the following cases:
(1) Minimum temperature >= threshold
dday = (tmax - tmin/2) - threshold
(2) Minimum temperature < Threshold < Maximum Temperature
dday = ( W integral_theta^pi/2 sin(t)dt - integral_theta^pi/2 (threshold - tmin)dt ) / pi
W = (tmax - tmin)/2
theta = sin^-1 [ ( tmax - tmin )/W ]
(3) Otherwise, degree days = 0
Snyder, Richard L. "Hand calculating degree days." Agricultural and forest meteorology 35, no. 1-4 (1985): 353-358.
Woodill, A. John "United States Temperature Exposure 1900-2013." (2016) http://johnwoodill.blogspot.com/2016/06/us-degree-days-heat-map-interesting.html
1 2 | data(napa)
degree_days(napa, thresholds = c(0:35))
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.