data(KA_weather)
hourtemps <- stack_hourly_temps(KA_weather, latitude=50.4)
iSeason <- genSeason(hourtemps, years=c(2009))
zc <- 190
yc <- 40
x <- PhenoFlex(temp=hourtemps$hourtemps$Temp[iSeason[[1]]],
times=c(1: length(hourtemps$hourtemps$Temp[iSeason[[1]]])),
zc=zc, stopatzc=TRUE, yc=yc, basic_output=FALSE)
DBreakDay <- x$bloomindex
ii <- c(1:DBreakDay)
plot(x=ii, y=x$z[ii], xlab="Hour Index", ylab="z", col="red", type="l")
abline(h=zc, lty=2)
plot(x=ii, y=x$y[ii], xlab="Hour Index", ylab="y", col="red", type="l")
abline(h=yc, lty=2)
Run the code above in your browser using DataLab