View source: R/utils-climate.R
gdd | R Documentation |
Calculate Growing Degree Days above a baseline baseline
, (GDD) from
daily values of temperature.
gdd(.data, ...)
## S3 method for class 'numeric'
gdd(.data, baseline = 0, pb = NULL, ...)
## S3 method for class 'tbl_df'
gdd(.data, baseline = 0, cpus = 1, ...)
.data |
Object with daily values of temperature. The object can be a:
|
... |
Optional parameters, including the |
baseline |
Numeric value to be used as the baseline for the calculation
of the Growing Degree Days, default: |
pb |
Function to signal the execution of one cycle (e.g.
|
cpus |
Numeric value with the number of CPUs to be used for the
computation. Default: |
If the input (.data
) is a
Numeric vector, it returns a single value for GDD.
Data frame (tibble
object), it returns the same data frame
with an additional column called gddX
(where X
represents
the value of the baseline
; e.g., gdd0
when
baseline = 0
), containing values for GDD.
plot_gdd
Other utils climate:
mat()
,
mi()
,
mtco()
,
mtwa()
## Not run:
`%>%` <- magrittr::`%>%`
data <- tibble::tibble(entity_name = "University of Reading",
latitude = 51.44140,
longitude = -0.9418,
elevation = 61)
smpds::gwr(.ref = "/path/to/reference-tmp.nc",
.tar = data,
varid = "tmp") %>%
smpds::pivot_data(varname = "tmp") %>%
smpds::gdd()
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.