WWmodel | R Documentation |
This is the main function for fitting WWmodel.
WWmodel(
modeldata,
ID,
date,
value,
covariate = NULL,
iteration,
burnin,
cores = 1
)
modeldata |
The long-format data frame/table of virus concentration |
ID |
Names of curve IDs (used to identify a unique curve) |
date |
Name of date column |
value |
Name of value column |
covariate |
Names of covariates (default is NULL) |
iteration |
A positive integer specifying the number of iterations for each chain (including burnin). |
burnin |
The number of burnin iterations |
This is the main function used to fit a WWmodel. See ?WWforecast and ?FORECASTplot for how to make forecasts using a fitted WWmodel.
fit The fitted MCMC model
rawdata = as.data.table(readRDS("ww-db-2021-09-10.rds"))
modeldata = DataPrep(rawdata, "N1")
ID = c("Location", "target", "replicate")
date = "date"
value = "log10.value.raw"
covariate = c("dinflvol", "temp")
model_res = WWmodel(modeldata, ID, date, value, covariate, 5000, 2500)
model_res$fit
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.