OSlOlSO
OSlOlSO

Reputation: 471

R: Generate a Seasonal ARIMA time-series model using parameters of existing data

I have a count time series data which I'm able to use to determine the parameters of the underlying stochastic process. For example say I have a SARIMA (p,d,q)(P,D,Q)[S] seasonal ARIMA model.

How do I use this to generate a new count time series data set?

Being even more specific: a SARIMA(1,0,1)(1,0,0)[12] - how can I generate a time series for a 10 year period for each month? (i.e., 120 points to estimate the number of 'counts'.)

Upvotes: 6

Views: 10063

Answers (2)

Juan M.
Juan M.

Reputation: 1

TS MA(2) From library(stats)

Number of elements 100, media=1, Standar Deviation=1 arima.sim(model = list(order = c(0,0,2)), n = 100, mean = 1, sd=1)

arima.sim(model, n, rand.gen = rnorm, innov = rand.gen(n, ...), n.start = NA, start.innov = rand.gen(n.start, ...), ...)

Upvotes: 0

Rob Hyndman
Rob Hyndman

Reputation: 31800

Use simulate.Arima() from the forecast package. It handles seasonal ARIMA models whereas arima.sim() does not.

However, ARIMA models are not suitable for count time series as they assume the process is defined on the whole real line.

Upvotes: 10

Related Questions