getP-methods(x12)
getP-methods()所属R语言包:x12
getP and setP for setting and loading parameters
getP和参数的设置和装载SETP
译者:生物统计家园网 机器人LoveR
描述----------Description----------
getP and setP for setting and loading parameters from a x12Single-class, x12Batch-class or x12Parameter-class object.
getP和setP设置和加载参数从一个x12Single-class,x12Batch-class或x12Parameter-class对象。
用法----------Usage----------
## S4 method for signature 'x12Single'
getP(object, whichP)
## S4 method for signature 'x12Batch'
getP(object, whichP,index=NULL)
## S4 method for signature 'x12Parameter'
getP(object, whichP)
## S4 method for signature 'x12Single'
setP(object, listP)
## S4 method for signature 'x12Batch'
setP(object, listP,index=NULL)
## S4 method for signature 'x12Parameter'
setP(object, listP)
参数----------Arguments----------
参数:object
object of class x12Single-class, x12Batch-class or x12Parameter-class.
对象类x12Single-class,x12Batch-class或x12Parameter-class。
参数:whichP
character vector with the names of the parameters to extract
与提取的参数名称的字符向量
参数:listP
named list of parameters to change
命名的参数列表
参数:index
index of the series in x12Batch-class to change or extract (NULL=all)
改变或提取指数x12Batch-class系列在(NULL =所有)
方法----------Methods----------
参见----------See Also----------
X12, x12Batch
X12,x12Batch
实例----------Examples----------
## Not run: [#不运行:]
#Create new batch object with 4 time series[创建一批新的对象有4个时间序列]
xb <- new("x12Batch",list(AirPassengers,AirPassengers,AirPassengers,AirPassengers))
# change the automdl to FALSE in all 4 elements[在所有4个元素为FALSE,改变automdl]
xb <- setP(xb,list(automdl=FALSE))
#change the arima and sarima setting for the first ts object[改变ARIMA和的SARIMA设置为第一个TS对象]
xb <- setP(xb,list(arima=c(1,1,0),sarima=c(1,1,0)),1)
#change the arima and sarima setting for the second ts object[改变ARIMA和的SARIMA设置为第二TS对象]
xb <- setP(xb,list(arima=c(0,1,1),sarima=c(0,1,1)),2)
#change the arima and sarima setting for the third ts object[改变ARIMA和的SARIMA设置为第三TS对象]
xb <- setP(xb,list(arima=c(0,1,1),sarima=c(1,1,1)),3)
#change the arima and sarima setting for the fourth ts object[改变ARIMA和的SARIMA设置为第四TS对象]
xb <- setP(xb,list(arima=c(1,1,1),sarima=c(1,1,1)),4)
#run X12 on all series[运行X12全系列]
xb <- X12(xb)
summary(xb)
#Set automdl=TRUE for the first ts[设置automdl的第一个TS = TRUE]
xb <- setP(xb,list(automdl=TRUE),1)
#rerun X12 on all series (the binaries will only run on the first one)[重新运行X12全系列(二进制文件将只能运行在第一个)]
xb <- X12(xb)
#summary with oldOutput[总结与oldOutput]
summary(xb,oldOutput=10)
#Change the parameter and output of the first series back to the first run[在第一次运行中改变参数和输出的第一串联回]
xb <- prev(xb,index=1,n=1)
#summary with oldOutput (--- No valid previous runs. ---)[总结oldOutput(---以前没有有效的运行。---)]
summary(xb,oldOutput=10)
## End(Not run)[#(不执行)]
转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。
注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
|