fit_simple_ts | R Documentation |
Estimate model
fit_simple_ts(
y,
ts_frequency = 1,
model = "quantile_baseline",
transformation = "box-cox",
transform_offset = 0.5,
d = 0,
D = 0,
...
)
y |
a univariate time series or numeric vector. |
ts_frequency |
frequency of time series. Must be provided if y is not of class "ts". See the help for stats::ts for more. |
model |
string specifying model to fit: one of 'quantile_baseline' or 'spline_smoother' |
transformation |
character specifying transformation type: "box-cox", "sqrt", "log", or "none". See details for more. |
transform_offset |
numeric offset used before the Box-Cox and log transformations; the offset is added to all observations before transforming. Default value of 0.5 allows us to use the Box-Cox and log transforms (which require positive inputs) in case of observations of 0, and also ensures that the reverse transformed values will always be at least -0.5, so that they round up to non-negative values. |
d |
integer order of first differencing; default is 0 |
D |
integer order of seasonal differencing; default is 0 |
... |
arguments passed on to model-specific fit method |
This function is a wrapper around model-specific fit methods, providing some preliminary transformations of the data. Formal and informal experimentation has shown these preliminary transformations to be helpful with a few infectious disease time series data sets.
a simple_ts model fit
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.