mixARExperiment | R Documentation |
Perform simulation experiments with MixAR models.
mixARExperiment(model, imodel = NULL, simargs = NULL, estargs = NULL, fix, ...)
model |
the underlying model, an object inheriting from "MixAR", see 'Details'. |
imodel |
initial model, an object inheriting from "MixAR", see 'Details'. |
simargs |
additional arguments for the simulation function, a list, see 'Details'. |
estargs |
additional arguments for the estimation function, a list, see 'Details'. |
fix |
which arguments to keep fixed during estimation; currently
if |
... |
additional arguments to pass on to |
mixARExperiment
is a wrapper for simuExperiment
.
The simulation function is mixARsim
and the estimation function
is fit_mixAR
. The simulation function gets model
as
first argument. The first argument of the estimation function is
imodel
, if supplied, or model
otherwise. Some
appropriate defaults for other arguments are also supplied. Arguments
simargs
and estargs
are needed only to override
defaults.
If fix = "shift"
, the shifts components are not estimated and
are kept fixed. This may be useful when fitting the model to
differenced series, for example.
mixARExperiment
sets keep
and summary_fun
to some
defaults (currently mixAR:::.fsumA
for the latter).
A list with one or more elements, depending on the arguments
...
passed on to simuExperiment
.
Summary |
a summary of the experiment, by default sample means and standard deviations of the estimates. This is a list of MixAR models. |
Raw |
A list of the estimated models. |
This is an initial version of this function, some of its arguments may change. Additional elements may be made available in the returned value, so refer to those by name, not with a numeric index.
Georgi N. Boshnakov
simuExperiment
exampleModels$WL_II
set.seed(1234)
n = 20 # toy size
N = 5 # toy number of simulations
mixARExperiment(exampleModels$WL_II, N = N, estargs = list(crit = 1e-4))
mixARExperiment(exampleModels$WL_II, N = N, raw = TRUE, estargs = list(crit = 1e-4))
mixARExperiment(exampleModels$WL_II, N = N, raw = TRUE,
simargs = list(n = n), estargs = list(crit = 1e-4) )
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.