The function predicts and returns the next n consecutive values of a set of
time series using automatically fitted ARIMA models. Based on multiple
application of the arimapred
function.
marimapred(
TimeSeries,
TimeSeriesCont = NULL,
n.ahead = NULL,
na.action = stats::na.omit,
xreg = NULL,
newxreg = NULL,
se.fit = FALSE,
plot = FALSE,
range.p = 0.2,
ylab = NULL,
xlab = NULL,
main = NULL
)
A vector, matrix, or data frame which contains a set of time series used for fitting ARIMA models. Each column corresponds to one time series.
A vector, matrix, or data frame containing
continuation points for TimeSeries
with actual values. Each column
corresponds to one time series. Ignored if NULL
.
A numeric vector (or a single numeric value) with the number
of consecutive values which are to be predicted of each respective time
series in TimeSeries
. If n.ahead
is NULL
, the number of
values to be predicted of each time series in TimeSeries
is assumed
to be equal to the number of rows in each respective time series in
TimeSeriesCont
. Required when TimeSeriesCont
is NULL
.
A function for treating missing values in TimeSeries
and TimeSeriesCont
. The default function is na.omit
,
which omits any missing values found in TimeSeries
or
TimeSeriesCont
.
A list of vectors, matrices, data frames or times series of
external regressors used for fitting the ARIMA models. The first component
of the list contains external regressors for the first time series in
TimeSeries
and therefore must have the same number of rows as this
respective time series. This is also valid for the second component, and so
forth. Ignored if NULL
.
A list of vectors, matrices, data frames or times series with
new values of xreg
to be used for prediction. The first component of
the list must have at least the same number of rows as the respective first
value in n.ahead
or, if n.ahead
is NULL
, the number of
continuation points in the respective first time series in
TimeSeriesCont
. This is also valid for the second component, and so
forth. Ignored if NULL
.
If se.fit
is TRUE
, the standard errors of the
predictions are returned.
A Boolean parameter which defines whether the function
arimapred
will generate a graphic. If plot
is
TRUE
, graphics will be generated for each time series in
TimeSeries
.
A percentage which defines how much the range of the graphics' y-axis will be increased from the minimum limits imposed by data.
A title for the graphics' y-axis. Ignored if NULL
.
~~Describe ylab
here~~
A title for the graphics' x-axis. Ignored if NULL
.
~~Describe xlab
here~~
An overall title for the graphics. Ignored if NULL
.
~~Describe main
here~~
A vector of time series of predictions, if the number of consecutive
values predicted of each time series in TimeSeries
is the same,
otherwise a list of time series of predictions.
If se.fit
is TRUE
, a vector of lists, each one with the
components pred
, the predictions, and se
, the estimated
standard errors. Both components are time series. See the
predict.Arima
function in the stats package and the function
arimapred
.
See the arimapred
function.
See the arimapred
function.
the literature/web site here ~
# NOT RUN {
data(SantaFe.A,SantaFe.A.cont)
marimapred(SantaFe.A,SantaFe.A.cont)
# }
Run the code above in your browser using DataLab