找回密码
 注册
查看: 5999|回复: 0

R语言:arima0()函数中文帮助文档(中英文对照)

[复制链接]
发表于 2012-2-17 10:03:48 | 显示全部楼层 |阅读模式
arima0(stats)
arima0()所属R语言包:stats

                                        ARIMA Modelling of Time Series – Preliminary Version
                                         时间序列的ARIMA模型建模 - 初稿

                                         译者:生物统计家园网 机器人LoveR

描述----------Description----------

Fit an ARIMA model to a univariate time series, and forecast from the fitted model.
适合一个单变量时间序列的ARIMA模型,并从拟合模型的预测。


用法----------Usage----------


arima0(x, order = c(0, 0, 0),
       seasonal = list(order = c(0, 0, 0), period = NA),
       xreg = NULL, include.mean = TRUE, delta = 0.01,
       transform.pars = TRUE, fixed = NULL, init = NULL,
       method = c("ML", "CSS"), n.cond, optim.control = list())

## S3 method for class 'arima0'
predict(object, n.ahead = 1, newxreg, se.fit = TRUE, ...)



参数----------Arguments----------

参数:x
a univariate time series
单变量的时间序列


参数:order
A specification of the non-seasonal part of the ARIMA model: the three components (p, d, q) are the AR order, the degree of differencing, and the MA order.
非季节性的ARIMA模型的规范的三个组成部分(p, d, q)是的AR秩序,一定程度的差异,以及马秩序。


参数:seasonal
A specification of the seasonal part of the ARIMA model, plus the period (which defaults to frequency(x)). This should be a list with components order and period, but a specification of just a numeric vector of length 3 will be turned into a suitable list with the specification as the order.
一个规范的季节ARIMA模型的一部分,加上期间(默认frequency(x))。这应该是一个组件列表order和period,但只是一个长度为3的数字向量的规范将到一个合适的名单与order规范。


参数:xreg
Optionally, a vector or matrix of external regressors, which must have the same number of rows as x.
或者,一个向量或矩阵的外部回归,必须有相同数量的行x。


参数:include.mean
Should the ARIMA model include a mean term? The default is TRUE for undifferenced series, FALSE for differenced ones (where a mean would not affect the fit nor predictions).
ARIMA模型应包括平均任期?默认是TRUE非差系列FALSE差的(平均不会影响到合适的,也不预测)。


参数:delta
A value to indicate at which point "fast recursions" should be used.  See the "Details" section.
一个值来表示点的快速递归应使用。看到“详细资料”一节。


参数:transform.pars
Logical.  If true, the AR parameters are transformed to ensure that they remain in the region of stationarity.  Not used for method = "CSS".
逻辑。如果情况属实,AR参数的改变,以确保它们保持在平稳的区域。不习惯method = "CSS"。


参数:fixed
optional numeric vector of the same length as the total number of parameters.  If supplied, only NA entries in fixed will be varied.  transform.pars = TRUE will be overridden (with a warning) if any ARMA parameters are fixed.
可选的数字作为参数的总数相同长度的向量。如果提供,仅NA项fixed将各不相同。 transform.pars = TRUE将重写(警告)如有ARMA参数是固定的。


参数:init
optional numeric vector of initial parameter values.  Missing values will be filled in, by zeroes except for regression coefficients.  Values already specified in fixed will be ignored.
可选的数字矢量的初始参数值。失踪的值将被填补,除了回归系数为零。已经fixed指定的值将被忽略。


参数:method
Fitting method: maximum likelihood or minimize conditional sum-of-squares.
拟合方法:最大的可能性或减少有条件的平方的总和。


参数:n.cond
Only used if fitting by conditional-sum-of-squares: the number of initial observations to ignore.  It will be ignored if less than the maximum lag of an AR term.
只用了,如果有条件和最小二乘拟合:忽略了初步意见。它会被忽略,如果小于最大的一个AR长期滞后。


参数:optim.control
List of control parameters for optim.
名单optim的控制参数。


参数:object
The result of an arima0 fit.
arima0合适的结果。


参数:newxreg
New values of xreg to be used for prediction. Must have at least n.ahead rows.
xreg新值用于预测。必须有至少n.ahead行。


参数:n.ahead
The number of steps ahead for which prediction is required.
的步数,提前预测需要。


参数:se.fit
Logical: should standard errors of prediction be returned?
逻辑:应退还预测标准误差?


参数:...
arguments passed to or from other methods.
参数传递或其他方法。


Details

详情----------Details----------

Different definitions of ARMA models have different signs for the AR and/or MA coefficients. The definition here has
ARMA模型有不同的定义有不同的AR和/或MA系数的迹象。这里有定义

and so the MA coefficients differ in sign from those of S-PLUS.  Further, if include.mean is true, this formula applies to X-m rather than X.  For ARIMA models with differencing, the differenced series follows a zero-mean ARMA model.
所以马系数不同,S-PLUS标志。此外,如果include.mean是真实的,该公式适用于X-m而不是X。 ARIMA模型与差异,差分系列如下零平均ARMA模型。

The variance matrix of the estimates is found from the Hessian of the log-likelihood, and so may only be a rough guide, especially for fits close to the boundary of invertibility.
从黑森州的对数似然估计的方差矩阵被发现,所以可能只是一个粗略的指南,尤其是紧靠可逆性边界。

Optimization is done by optim. It will work best if the columns in xreg are roughly scaled to zero mean and unit variance, but does attempt to estimate suitable scalings.
优化完成optim。它将工作最好的,如果在列xreg大致缩小到零均值和单位方差,但没有试图估计合适的结垢。

Finite-history prediction is used. This is only statistically efficient if the MA part of the fit is invertible, so predict.arima0 will give a warning for non-invertible MA models.
使用有限的历史预测。这是只统计有效的,如果合适的马是可逆的,所以predict.arima0会给一个不可逆的马模型的警告。


值----------Value----------

For arima0, a list of class "arima0" with components:
对于arima0类"arima0"组件列表:


参数:coef
a vector of AR, MA and regression coefficients,
向量的AR,马和回归系数,


参数:sigma2
the MLE of the innovations variance.
创新方差MLE。


参数:var.coef
the estimated variance matrix of the coefficients coef.
的系数coef的估计方差矩阵。


参数:loglik
the maximized log-likelihood (of the differenced data), or the approximation to it used.
最大化日志的可能性(差分数据),或近似的使用。


参数:arma
A compact form of the specification, as a vector giving the number of AR, MA, seasonal AR and seasonal MA coefficients, plus the period and the number of non-seasonal and seasonal differences.
一个紧凑的形式规范,作为向量提供的AR,MA,季节性AR和季节性马系数,加上期间和非季节性和季节性差异。


参数:aic
the AIC value corresponding to the log-likelihood. Only valid for method = "ML" fits.
AIC值,相应的对数似然。只method = "ML"有效适合。


参数:residuals
the fitted innovations.
拟合的创新。


参数:call
the matched call.
匹配的呼叫。


参数:series
the name of the series x.
名称系列x。


参数:convergence
the value returned by optim.
optim返回的值。


参数:n.cond
the number of initial observations not used in the fitting.
不是在装修中使用的初步意见。

For predict.arima0, a time series of predictions, or if se.fit = TRUE, a list with components pred, the predictions, and se, the estimated standard errors. Both components are time series.
对于predict.arima0,时间序列的预测,或者如果se.fit = TRUE,一个组件的列表pred,预测,se,估计标准误差。这两个组件是时间序列。


拟合方法----------Fitting methods----------

The exact likelihood is computed via a state-space representation of the ARMA process, and the innovations and their variance found by a Kalman filter based on Gardner et al. (1980).  This has the option to switch to "fast recursions" (assume an effectively infinite past) if the innovations variance is close enough to its asymptotic bound. The argument delta sets the tolerance: at its default value the approximation is normally negligible and the speed-up considerable.  Exact computations can be ensured by setting delta to a negative value.
通过的ARMA过程的状态空间表示,创新和卡尔曼滤波器基于Gardner等发现的方差计算确切的可能性。 (1980年)。这选项,切换到“快速递归”(假设一个有效无限的过去),如果是足够接近其渐近绑定的创新方差。参数delta设置公差:在它的默认值近似通常是可以忽略不计和速度相当。精确的计算,可以保证通过设置delta为负值。

If transform.pars is true, the optimization is done using an alternative parametrization which is a variation on that suggested by Jones (1980) and ensures that the model is stationary.  For an AR(p) model the parametrization is via the inverse tanh of the partial autocorrelations: the same procedure is applied (separately) to the AR and seasonal AR terms.  The MA terms are also constrained to be invertible during optimization by the same transformation if transform.pars is true.  Note that the MLE for MA terms does sometimes occur for MA polynomials with unit roots: such models can be fitted by using transform.pars = FALSE and specifying a good set of initial values (often obtainable from a fit with transform.pars = TRUE).
transform.pars如果是真实的,使用替代参数化,这是由琼斯(1980年)的建议,并确保该模型是静止的变化进行优化。对于AR(p)模型的参数化是通过反偏自相关的tanh:应用相同的过程(分别)AR和季节性AR条款。马条款也限制在相同的转换transform.pars如果是真实的优化是可逆的。请注意,马条款的MLE,有时会发生马多项式单位根:这种模型可以安装使用transform.pars = FALSE和一套好的指定一个初始值(从transform.pars = TRUE适合经常索取) 。

Missing values are allowed, but any missing values will force delta to be ignored and full recursions used. Note that missing values will be propagated by differencing, so the procedure used in this function is not fully efficient in that case.
遗漏值是允许的,但任何遗漏值将迫使delta被忽略和完全递归使用。注意遗漏值将传播差异,所以在这个函数中所使用的程序是,在这种情况下不完全有效的。

Conditional sum-of-squares is provided mainly for expositional purposes.  This computes the sum of squares of the fitted innovations from observation n.cond on, (where n.cond is at least the maximum lag of an AR term), treating all earlier innovations to be zero.  Argument n.cond can be used to allow comparability between different fits.  The "part log-likelihood" is the first term, half the log of the estimated mean square.  Missing values are allowed, but will cause many of the innovations to be missing.
有条件的总和平方提供主要用于expositional目的。这拟合创新的平方的总和计算,从观察n.cond(其中n.cond至少是最大的一个AR长期滞后),处理所有早期的创新,是零。参数n.cond可以用来允许不同的配合之间的可比性。 的一部分日志的可能性“是第一个任期内,有一半的估计均方的日志。遗漏值是允许的,但将导致许多创新的缺失。

When regressors are specified, they are orthogonalized prior to fitting unless any of the coefficients is fixed.  It can be helpful to roughly scale the regressors to zero mean and unit variance.
当回归是指定的,它们是正交前装修,除非是固定的系数。它可以帮助大致规模回归到零均值和单位方差。


注意----------Note----------

This is a preliminary version, and will be replaced by arima.
这是一个初步的版本,将被替换arima。

The standard errors of prediction exclude the uncertainty in the estimation of the ARMA model and the regression coefficients.
预测标准误差排除在ARMA模型的估计和回归系数的不确定性。

The results are likely to be different from S-PLUS's arima.mle, which computes a conditional likelihood and does not include a mean in the model.  Further, the convention used by arima.mle reverses the signs of the MA coefficients.
其结果很可能是从不同,S-PLUS的arima.mle,计算条件的可能性,不包括在模型中的平均。此外,arima.mle公约反转的MA系数的迹象。


参考文献----------References----------

Series and Forecasting. Springer, New York. Sections 3.3 and 8.3.
AS154. An algorithm for exact maximum likelihood estimation of autoregressive-moving average models by means of Kalman filtering. Applied Statistics 29, 311–322.
2nd Edition, Harvester Wheatsheaf, sections 3.3 and  4.4.
An algorithm for finite sample prediction from ARIMA processes. Applied Statistics 31, 180–187.
series with missing observations. Technometrics 20 389–395.

参见----------See Also----------

arima, ar, tsdiag
arima,ar,tsdiag


举例----------Examples----------


## Not run: arima0(lh, order = c(1,0,0))[#运行:arima0(LH,为了= C(1,0,0))]
arima0(lh, order = c(3,0,0))
arima0(lh, order = c(1,0,1))
predict(arima0(lh, order = c(3,0,0)), n.ahead = 12)

arima0(lh, order = c(3,0,0), method = "CSS")

# for a model with as few years as this, we want full ML[一个模型,因为这几年,我们要充分的ML]
(fit <- arima0(USAccDeaths, order = c(0,1,1),
               seasonal = list(order=c(0,1,1)), delta = -1))
predict(fit, n.ahead = 6)

arima0(LakeHuron, order = c(2,0,0), xreg = time(LakeHuron)-1920)
## Not run: [#无法运行:]
## presidents contains NAs[#总统包含定居]
## graphs in example(acf) suggest order 1 or 3[#例如图(ACF)建议1阶或3]
(fit1 &lt;- arima0(presidents, c(1, 0, 0), delta = -1))  # avoid warning[避免警告]
tsdiag(fit1)
(fit3 &lt;- arima0(presidents, c(3, 0, 0), delta = -1))  # smaller AIC[较小的工商行政管理机关]
tsdiag(fit3)
## End(Not run)[#结束(不运行)]

转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。


注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

手机版|小黑屋|生物统计家园 网站价格

GMT+8, 2025-1-22 23:46 , Processed in 0.020683 second(s), 16 queries .

Powered by Discuz! X3.5

© 2001-2024 Discuz! Team.

快速回复 返回顶部 返回列表