| armaErr | R Documentation |
armaErr class generator using arima.simarmaErr class generator using arima.sim
armaErr class generator using arima.sim
PersonAlyticsPower::err -> errARMA
modelThe parameters for FUN.
errVarThe error variance.
FUNThe function for simulating error terms.
famA gamlss.family family for the error term distribution.
After data are simulated using FUN and its model, it can be
transformed to have a distribution different from those available to FUN.
famParmsParameters to be passed to fam, see gamlss.family.
modelThe parameters for FUN.
errVarThe error variance.
FUNThe function for simulating error terms.
famA gamlss.family family for the error term distribution.
After data are simulated using FUN and its model, it can be
transformed to have a distribution different from those available to FUN.
famParmsParameters to be passed to fam, see gamlss.family.
new()armaErr$new( model = list(ar = c(0.5), ma = c(0)), fam = "NO", famParms = list(mu = 0, sigma = 1) )
checkModel()armaErr$checkModel( seed = 1234, n = 1000, doPlot = TRUE, doStats = TRUE, debug = FALSE )
makeErrors()armaErr$makeErrors(n, nObservations, seed = 123, debug = FALSE)
clone()The objects of this class are cloneable with this method.
armaErr$clone(deep = FALSE)
deepWhether to make a deep clone.
Stephen Tueller stueller@rti.org
# set up a stationary arma model
testErr <- armaErr$new(model = list(ar=c(.5), ma=c(.2)))
testErr$checkModel()
# show testing for an unstationary ARMA model
testFail <- armaErr$new(model = list(ar=c(-.8, .5), ma=c(.2)))
testFail$checkModel()
# show that r* functions from gamlss.family distribution functions can be
# passed to arima.sim
errBeta <- arima.sim(list(ar=c(.5)), 1000, innov = rBE(1000, mu=.5, sigma=.2))
# note that the rand.gen option only allows the defaults for the function
# passed to rand.gen
#errBeta <- arima.sim(list(ar=c(.5)), 1000, rand.gen = rBE)
# that said, rand.gen's parameters can be passed via ...
#errBeta <- arima.sim(list(ar=c(.5)), 1000, rand.gen = rBE, mu=.9, sigma=.2)
# note that even though beta innovations are used, the resulting data is not
# constrained to be in (0,1)
hist(errBeta)
plot(errBeta)
auto.arima(ts(errBeta))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.