gseason_temp: gseason_temp: Calculates the growing season period as...

Description Usage Arguments Details Value See Also Examples

Description

gseason_temp calculates growing season period where temperatures are above 'lower' and below 'upper' specified limits.

Usage

1
gseason_temp(temp, tme, lower = 5, upper = 35, nday = 5)

Arguments

temp

a vector of temperature values.

tme

a POSIXlt object representing the date and time of each temps value.

lower

integer specifying lower temperature limit of growing season.

upper

integer specifying upper temperature limit of growing season.

nday

specifies the number of consecutive days of temperatures above 'lower' or below 'upper' before growing season start/end is accepted.

Details

To satisfy the requirements for tme, a POSIXlt object can be created using the tmecreate wrapper function.

Value

A time-series object of binary values, where 1 indicates growing season and 0 indicates not growing season.

See Also

tmecreate() can be used to create a POSIXlt object.

Examples

1
2
3
4
temps <- 10 * sin(c(0:1459) / (pi * 150)) + rnorm(1460)
tme <- tmecreate(2010, 6)
gseast <- gseason_temp(temps, tme)
plot(gseast)

ilyamaclean/climvars documentation built on June 19, 2019, 2:22 p.m.