View source: R/plotStumpTemp.R
plotStumpTemp | R Documentation |
Plot Stump Temperature Time Series. This function plots stump temperature data over time, either in days or months. The data can be grouped by month and/or averaged over each month.
plotStumpTemp(
model,
type = c("days", "month"),
startDate = as.Date("2000-01-01"),
groupMonth = F,
avgMonth = F
)
model |
Output from the |
type |
A character vector specifying the type of time series plot. Can be 'days' or 'month'. Default is 'days'. |
startDate |
A Date object representing the starting date of the time series. Default is "2000-01-01". Only used when displaying Months (see details). |
groupMonth |
A logical value. If TRUE, the data will be grouped by Month and displayed as a single point for each group. Default is FALSE. |
avgMonth |
A logical value. If TRUE, the data will be averaged for each month across the entire time series. Default is FALSE. |
The 'startDate', 'groupMonth', and 'avgMonth' arguments are only used when
selecting type = 'month'
. The 'startDate' argument is used to set the starting
date of the data and should be in the form as.Date(myDate)
. However, if type = 'days'
then the 'startDate', 'groupMonth', and 'avgMonth' arguments are ignored.
A ggplot object displaying the stump temperature time series.
data(weatherData)
mod <- piner(data = weatherData,
npop = 100,
ntimes = 10,
species = 2,
output = 0)
plotStumpTemp(model = mod, startDate = as.Date("2020-01-01"), type = "month", avgMonth = TRUE)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.