多种产品的预测精度计算

时间:2019-04-05 14:43:14

标签: r forecasting

我正在为论文进行间歇性需求预测。但是对于我正在使用R的方法的应用,我对此并不十分有经验。 在我的数据集中,我有301个库存单位(SKU)。对于预测部分,我使用“ tsintermittent”包,Croston方法,SBA和单指数平滑。通过使用“应用”功能,我能够生成不同参数的预测。但是,对于准确性度量,我无法使用apply函数。是否有可能在短时间内计算出301个SKU的MASE,sMAPE,MSE和MAD?

P.S。我还必须计算所有介于0.05-0.95和最佳值之间的alpha值的度量。

n.cr005 <- apply(s.train_t, 2, crost, h = 12, w = 0.05, init = c("naive"),init.opt=FALSE)
n.cr010 <- apply(s.train_t, 2, crost, h = 12, w = 0.10, init = c("naive"),init.opt=FALSE)
n.cr015 <- apply(s.train_t, 2, crost, h = 12, w = 0.15, init = c("naive"),init.opt=FALSE)
n.cr020 <- apply(s.train_t, 2, crost, h = 12, w = 0.20, init = c("naive"),init.opt=FALSE)
n.cr025 <- apply(s.train_t, 2, crost, h = 12, w = 0.25, init = c("naive"),init.opt=FALSE)
n.cr030 <- apply(s.train_t, 2, crost, h = 12, w = 0.30, init = c("naive"),init.opt=FALSE)
n.cr035 <- apply(s.train_t, 2, crost, h = 12, w = 0.35, init = c("naive"),init.opt=FALSE)
n.cr040 <- apply(s.train_t, 2, crost, h = 12, w = 0.40, init = c("naive"),init.opt=FALSE)
n.cr045 <- apply(s.train_t, 2, crost, h = 12, w = 0.45, init = c("naive"),init.opt=FALSE)
n.cr050 <- apply(s.train_t, 2, crost, h = 12, w = 0.50, init = c("naive"),init.opt=FALSE)
n.cr055 <- apply(s.train_t, 2, crost, h = 12, w = 0.55, init = c("naive"),init.opt=FALSE)
n.cr060 <- apply(s.train_t, 2, crost, h = 12, w = 0.60, init = c("naive"),init.opt=FALSE)
n.cr065 <- apply(s.train_t, 2, crost, h = 12, w = 0.65, init = c("naive"),init.opt=FALSE)
n.cr070 <- apply(s.train_t, 2, crost, h = 12, w = 0.70, init = c("naive"),init.opt=FALSE)
n.cr075 <- apply(s.train_t, 2, crost, h = 12, w = 0.75, init = c("naive"),init.opt=FALSE)
n.cr080 <- apply(s.train_t, 2, crost, h = 12, w = 0.80, init = c("naive"),init.opt=FALSE)
n.cr085 <- apply(s.train_t, 2, crost, h = 12, w = 0.85, init = c("naive"),init.opt=FALSE)
n.cr090 <- apply(s.train_t, 2, crost, h = 12, w = 0.90, init = c("naive"),init.opt=FALSE)
n.cr095 <- apply(s.train_t, 2, crost, h = 12, w = 0.95, init = c("naive"),init.opt=FALSE)
m.cr005 <- apply(s.train_t, 2, crost, h = 12, w = 0.05, init = c("mean"),init.opt=FALSE)
m.cr010 <- apply(s.train_t, 2, crost, h = 12, w = 0.10, init = c("mean"),init.opt=FALSE)
m.cr015 <- apply(s.train_t, 2, crost, h = 12, w = 0.15, init = c("mean"),init.opt=FALSE)
m.cr020 <- apply(s.train_t, 2, crost, h = 12, w = 0.20, init = c("mean"),init.opt=FALSE)
m.cr025 <- apply(s.train_t, 2, crost, h = 12, w = 0.25, init = c("mean"),init.opt=FALSE)
m.cr030 <- apply(s.train_t, 2, crost, h = 12, w = 0.30, init = c("mean"),init.opt=FALSE)
m.cr035 <- apply(s.train_t, 2, crost, h = 12, w = 0.35, init = c("mean"),init.opt=FALSE)
m.cr040 <- apply(s.train_t, 2, crost, h = 12, w = 0.40, init = c("mean"),init.opt=FALSE)
m.cr045 <- apply(s.train_t, 2, crost, h = 12, w = 0.45, init = c("mean"),init.opt=FALSE)
m.cr050 <- apply(s.train_t, 2, crost, h = 12, w = 0.50, init = c("mean"),init.opt=FALSE)
m.cr055 <- apply(s.train_t, 2, crost, h = 12, w = 0.55, init = c("mean"),init.opt=FALSE)
m.cr060 <- apply(s.train_t, 2, crost, h = 12, w = 0.60, init = c("mean"),init.opt=FALSE)
m.cr065 <- apply(s.train_t, 2, crost, h = 12, w = 0.65, init = c("mean"),init.opt=FALSE)
m.cr070 <- apply(s.train_t, 2, crost, h = 12, w = 0.70, init = c("mean"),init.opt=FALSE)
m.cr075 <- apply(s.train_t, 2, crost, h = 12, w = 0.75, init = c("mean"),init.opt=FALSE)
m.cr080 <- apply(s.train_t, 2, crost, h = 12, w = 0.80, init = c("mean"),init.opt=FALSE)
m.cr085 <- apply(s.train_t, 2, crost, h = 12, w = 0.85, init = c("mean"),init.opt=FALSE)
m.cr090 <- apply(s.train_t, 2, crost, h = 12, w = 0.90, init = c("mean"),init.opt=FALSE)
m.cr095 <- apply(s.train_t, 2, crost, h = 12, w = 0.95, init = c("mean"),init.opt=FALSE)
o.crmar1 <- apply(s.train_t, 2, crost, h = 12, nop= c(1), cost =c("mar") ,init.opt=TRUE)
o.crmar2 <- apply(s.train_t, 2, crost, h = 12, nop= c(2), cost =c("mar") ,init.opt=TRUE)
o.crmsr1 <- apply(s.train_t, 2, crost, h = 12, nop= c(1), cost =c("msr") ,init.opt=TRUE)
o.crmsr2 <- apply(s.train_t, 2, crost, h = 12, nop= c(2), cost =c("msr") ,init.opt=TRUE)
o.crmae1 <- apply(s.train_t, 2, crost, h = 12, nop= c(1), cost =c("mae") ,init.opt=TRUE)
o.crmae2 <- apply(s.train_t, 2, crost, h = 12, nop= c(2), cost =c("mae") ,init.opt=TRUE)
o.crmse1 <- apply(s.train_t, 2, crost, h = 12, nop= c(1), cost =c("mae") ,init.opt=TRUE)
o.crmse2 <- apply(s.train_t, 2, crost, h = 12, nop= c(2), cost =c("mae") ,init.opt=TRUE)

mae.m.cr005.p14 <- MAE(s.test_t$V1,m.cr005[[1]]$frc.out, digits= 1)
mse.m.cr005.p14 <- MSE(s.test_t$V1,m.cr005[[1]]$frc.out, digits= 1)
smape.m.cr005.p14 <- SMAPE(s.test_t$V1,m.cr005[[1]]$frc.out, digits= 1)
mase.m.cr005.p14 <- mase(s.test_t$V1,m.cr005[[1]]$frc.out, step_size=1)
mae.m.cr010.p14 <- MAE(s.test_t$V1,m.cr010[[1]]$frc.out, digits= 3)
mse.m.cr010.p14 <- MSE(s.test_t$V1,m.cr010[[1]]$frc.out, digits= 3)
smape.m.cr010.p14 <- SMAPE(s.test_t$V1,m.cr010[[1]]$frc.out, digits= 3)
mase.m.cr010.p14 <- mase(s.test_t$V1,m.cr010[[1]]$frc.out, step_size=1)
mae.m.cr015.p14 <- MAE(s.test_t$V1,m.cr015[[1]]$frc.out, digits= 3)
mse.m.cr015.p14 <- MSE(s.test_t$V1,m.cr015[[1]]$frc.out, digits= 3)
smape.m.cr015.p14 <- SMAPE(s.test_t$V1,m.cr015[[1]]$frc.out, digits= 3)
mase.m.cr015.p14 <- mase(s.test_t$V1,m.cr015[[1]]$frc.out, step_size=1)
mae.m.cr020.p14 <- MAE(s.test_t$V1,m.cr020[[1]]$frc.out, digits= 3)
mse.m.cr020.p14 <- MSE(s.test_t$V1,m.cr020[[1]]$frc.out, digits= 3)
smape.m.cr020.p14 <- SMAPE(s.test_t$V1,m.cr020[[1]]$frc.out, digits= 3)
mase.m.cr020.p14 <- mase(s.test_t$V1,m.cr020[[1]]$frc.out, step_size=1)
mae.m.cr025.p14 <- MAE(s.test_t$V1,m.cr025[[1]]$frc.out, digits= 3)
mse.m.cr025.p14 <- MSE(s.test_t$V1,m.cr025[[1]]$frc.out, digits= 3)
smape.m.cr025.p14 <- SMAPE(s.test_t$V1,m.cr025[[1]]$frc.out, digits= 3)
mase.m.cr025.p14 <- mase(s.test_t$V1,m.cr025[[1]]$frc.out, step_size=1)
mae.m.cr030.p14 <- MAE(s.test_t$V1,m.cr030[[1]]$frc.out, digits= 3)
mse.m.cr030.p14 <- MSE(s.test_t$V1,m.cr030[[1]]$frc.out, digits= 3)
smape.m.cr030.p14 <- SMAPE(s.test_t$V1,m.cr030[[1]]$frc.out, digits= 3)
mase.m.cr030.p14 <- mase(s.test_t$V1,m.cr030[[1]]$frc.out, step_size=1)
mae.m.cr035.p14 <- MAE(s.test_t$V1,m.cr035[[1]]$frc.out, digits= 3)
mse.m.cr035.p14 <- MSE(s.test_t$V1,m.cr035[[1]]$frc.out, digits= 3)
smape.m.cr035.p14 <- SMAPE(s.test_t$V1,m.cr035[[1]]$frc.out, digits= 3)
mase.m.cr035.p14 <- mase(s.test_t$V1,m.cr035[[1]]$frc.out, step_size=1)
mae.m.cr040.p14 <- MAE(s.test_t$V1,m.cr040[[1]]$frc.out, digits= 3)
mse.m.cr040.p14 <- MSE(s.test_t$V1,m.cr040[[1]]$frc.out, digits= 3)
smape.m.cr040.p14 <- SMAPE(s.test_t$V1,m.cr040[[1]]$frc.out, digits= 3)
mase.m.cr040.p14 <- mase(s.test_t$V1,m.cr040[[1]]$frc.out, step_size=1)
mae.m.cr045.p14 <- MAE(s.test_t$V1,m.cr045[[1]]$frc.out, digits= 3)
mse.m.cr045.p14 <- MSE(s.test_t$V1,m.cr045[[1]]$frc.out, digits= 3)
smape.m.cr045.p14 <- SMAPE(s.test_t$V1,m.cr045[[1]]$frc.out, digits= 3)
mase.m.cr045.p14 <- mase(s.test_t$V1,m.cr045[[1]]$frc.out, step_size=1)
mae.m.cr050.p14 <- MAE(s.test_t$V1,m.cr050[[1]]$frc.out, digits= 3)
mse.m.cr050.p14 <- MSE(s.test_t$V1,m.cr050[[1]]$frc.out, digits= 3)
smape.m.cr050.p14 <- SMAPE(s.test_t$V1,m.cr050[[1]]$frc.out, digits= 3)
mase.m.cr050.p14 <- mase(s.test_t$V1,m.cr050[[1]]$frc.out, step_size=1)
mae.m.cr055.p14 <- MAE(s.test_t$V1,m.cr055[[1]]$frc.out, digits= 3)
mse.m.cr055.p14 <- MSE(s.test_t$V1,m.cr055[[1]]$frc.out, digits= 3)
smape.m.cr055.p14 <- SMAPE(s.test_t$V1,m.cr055[[1]]$frc.out, digits= 3)
mase.m.cr055.p14 <- mase(s.test_t$V1,m.cr055[[1]]$frc.out, step_size=1)
mae.m.cr060.p14 <- MAE(s.test_t$V1,m.cr060[[1]]$frc.out, digits= 3)
mse.m.cr060.p14 <- MSE(s.test_t$V1,m.cr060[[1]]$frc.out, digits= 3)
smape.m.cr060.p14 <- SMAPE(s.test_t$V1,m.cr060[[1]]$frc.out, digits= 3)
mase.m.cr060.p14 <- mase(s.test_t$V1,m.cr060[[1]]$frc.out, step_size=1)
mae.m.cr065.p14 <- MAE(s.test_t$V1,m.cr065[[1]]$frc.out, digits= 3)
mse.m.cr065.p14 <- MSE(s.test_t$V1,m.cr065[[1]]$frc.out, digits= 3)
smape.m.cr065.p14 <- SMAPE(s.test_t$V1,m.cr065[[1]]$frc.out, digits= 3)
mase.m.cr065.p14 <- mase(s.test_t$V1,m.cr065[[1]]$frc.out, step_size=1)
mae.m.cr070.p14 <- MAE(s.test_t$V1,m.cr070[[1]]$frc.out, digits= 3)
mse.m.cr070.p14 <- MSE(s.test_t$V1,m.cr070[[1]]$frc.out, digits= 3)
smape.m.cr070.p14 <- SMAPE(s.test_t$V1,m.cr070[[1]]$frc.out, digits= 3)
mase.m.cr070.p14 <- mase(s.test_t$V1,m.cr070[[1]]$frc.out, step_size=1)
mae.m.cr075.p14 <- MAE(s.test_t$V1,m.cr075[[1]]$frc.out, digits= 3)
mse.m.cr075.p14 <- MSE(s.test_t$V1,m.cr075[[1]]$frc.out, digits= 3)
smape.m.cr075.p14 <- SMAPE(s.test_t$V1,m.cr075[[1]]$frc.out, digits= 3)
mase.m.cr075.p14 <- mase(s.test_t$V1,m.cr075[[1]]$frc.out, step_size=1)
mae.m.cr080.p14 <- MAE(s.test_t$V1,m.cr080[[1]]$frc.out, digits= 3)
mse.m.cr080.p14 <- MSE(s.test_t$V1,m.cr080[[1]]$frc.out, digits= 3)
smape.m.cr080.p14 <- SMAPE(s.test_t$V1,m.cr080[[1]]$frc.out, digits= 3)
mase.m.cr080.p14 <- mase(s.test_t$V1,m.cr080[[1]]$frc.out, step_size=1)
mae.m.cr085.p14 <- MAE(s.test_t$V1,m.cr085[[1]]$frc.out, digits= 3)
mse.m.cr085.p14 <- MSE(s.test_t$V1,m.cr085[[1]]$frc.out, digits= 3)
smape.m.cr085.p14 <- SMAPE(s.test_t$V1,m.cr085[[1]]$frc.out, digits= 3)
mase.m.cr085.p14 <- mase(s.test_t$V1,m.cr085[[1]]$frc.out, step_size=1)
mae.m.cr090.p14 <- MAE(s.test_t$V1,m.cr090[[1]]$frc.out, digits= 3)
mse.m.cr090.p14 <- MSE(s.test_t$V1,m.cr090[[1]]$frc.out, digits= 3)
smape.m.cr090.p14 <- SMAPE(s.test_t$V1,m.cr090[[1]]$frc.out, digits= 3)
mase.m.cr090.p14 <- mase(s.test_t$V1,m.cr090[[1]]$frc.out, step_size=1)
mae.m.cr095.p14 <- MAE(s.test_t$V1,m.cr095[[1]]$frc.out, digits= 3)
mse.m.cr095.p14 <- MSE(s.test_t$V1,m.cr095[[1]]$frc.out, digits= 3)
smape.m.cr095.p14 <- SMAPE(s.test_t$V1,m.cr095[[1]]$frc.out, digits= 3)
mase.m.cr095.p14 <- mase(s.test_t$V1,m.cr095[[1]]$frc.out, step_size=1)
mae.n.cr005.p14 <- MAE(s.test_t$V1,n.cr005[[1]]$frc.out, digits= 3)
mse.n.cr005.p14 <- MSE(s.test_t$V1,n.cr005[[1]]$frc.out, digits= 3)
smape.n.cr005.p14 <- SMAPE(s.test_t$V1,n.cr005[[1]]$frc.out, digits= 3)
mase.n.cr005.p14 <- mase(s.test_t$V1,n.cr005[[1]]$frc.out, step_size=1)
mae.n.cr010.p14 <- MAE(s.test_t$V1,n.cr010[[1]]$frc.out, digits= 3)
mse.n.cr010.p14 <- MSE(s.test_t$V1,n.cr010[[1]]$frc.out, digits= 3)
smape.n.cr010.p14 <- SMAPE(s.test_t$V1,n.cr010[[1]]$frc.out, digits= 3)
mase.n.cr010.p14 <- mase(s.test_t$V1,n.cr010[[1]]$frc.out, step_size=1)
mae.n.cr015.p14 <- MAE(s.test_t$V1,n.cr015[[1]]$frc.out, digits= 3)
mse.n.cr015.p14 <- MSE(s.test_t$V1,n.cr015[[1]]$frc.out, digits= 3)
smape.n.cr015.p14 <- SMAPE(s.test_t$V1,n.cr015[[1]]$frc.out, digits= 3)
mase.n.cr015.p14 <- mase(s.test_t$V1,n.cr015[[1]]$frc.out, step_size=1)
mae.n.cr020.p14 <- MAE(s.test_t$V1,n.cr020[[1]]$frc.out, digits= 3)
mse.n.cr020.p14 <- MSE(s.test_t$V1,n.cr020[[1]]$frc.out, digits= 3)
smape.n.cr020.p14 <- SMAPE(s.test_t$V1,n.cr020[[1]]$frc.out, digits= 3)
mase.n.cr020.p14 <- mase(s.test_t$V1,n.cr020[[1]]$frc.out, step_size=1)
mae.n.cr025.p14 <- MAE(s.test_t$V1,n.cr025[[1]]$frc.out, digits= 3)
mse.n.cr025.p14 <- MSE(s.test_t$V1,n.cr025[[1]]$frc.out, digits= 3)
smape.n.cr025.p14 <- SMAPE(s.test_t$V1,n.cr025[[1]]$frc.out, digits= 3)
mase.n.cr025.p14 <- mase(s.test_t$V1,n.cr025[[1]]$frc.out, step_size=1)
mae.n.cr030.p14 <- MAE(s.test_t$V1,n.cr030[[1]]$frc.out, digits= 3)
mse.n.cr030.p14 <- MSE(s.test_t$V1,n.cr030[[1]]$frc.out, digits= 3)
smape.n.cr030.p14 <- SMAPE(s.test_t$V1,n.cr030[[1]]$frc.out, digits= 3)
mase.n.cr030.p14 <- mase(s.test_t$V1,n.cr030[[1]]$frc.out, step_size=1)
mae.n.cr035.p14 <- MAE(s.test_t$V1,n.cr035[[1]]$frc.out, digits= 3)
mse.n.cr035.p14 <- MSE(s.test_t$V1,n.cr035[[1]]$frc.out, digits= 3)
smape.n.cr035.p14 <- SMAPE(s.test_t$V1,n.cr035[[1]]$frc.out, digits= 3)
mase.n.cr035.p14 <- mase(s.test_t$V1,n.cr035[[1]]$frc.out, step_size=1)
mae.n.cr040.p14 <- MAE(s.test_t$V1,n.cr040[[1]]$frc.out, digits= 3)
mse.n.cr040.p14 <- MSE(s.test_t$V1,n.cr040[[1]]$frc.out, digits= 3)
smape.n.cr040.p14 <- SMAPE(s.test_t$V1,n.cr040[[1]]$frc.out, digits= 3)
mase.n.cr040.p14 <- mase(s.test_t$V1,n.cr040[[1]]$frc.out, step_size=1)
mae.n.cr045.p14 <- MAE(s.test_t$V1,n.cr045[[1]]$frc.out, digits= 3)
mse.n.cr045.p14 <- MSE(s.test_t$V1,n.cr045[[1]]$frc.out, digits= 3)
smape.n.cr045.p14 <- SMAPE(s.test_t$V1,n.cr045[[1]]$frc.out, digits= 3)
mase.n.cr045.p14 <- mase(s.test_t$V1,n.cr045[[1]]$frc.out, step_size=1)
mae.n.cr050.p14 <- MAE(s.test_t$V1,n.cr050[[1]]$frc.out, digits= 3)
mse.n.cr050.p14 <- MSE(s.test_t$V1,n.cr050[[1]]$frc.out, digits= 3)
smape.n.cr050.p14 <- SMAPE(s.test_t$V1,n.cr050[[1]]$frc.out, digits= 3)
mase.n.cr050.p14 <- mase(s.test_t$V1,n.cr050[[1]]$frc.out, step_size=1)
mae.n.cr055.p14 <- MAE(s.test_t$V1,n.cr055[[1]]$frc.out, digits= 3)
mse.n.cr055.p14 <- MSE(s.test_t$V1,n.cr055[[1]]$frc.out, digits= 3)
smape.n.cr055.p14 <- SMAPE(s.test_t$V1,n.cr055[[1]]$frc.out, digits= 3)
mase.n.cr055.p14 <- mase(s.test_t$V1,n.cr055[[1]]$frc.out, step_size=1)
mae.n.cr060.p14 <- MAE(s.test_t$V1,n.cr060[[1]]$frc.out, digits= 3)
mse.n.cr060.p14 <- MSE(s.test_t$V1,n.cr060[[1]]$frc.out, digits= 3)
smape.n.cr060.p14 <- SMAPE(s.test_t$V1,n.cr060[[1]]$frc.out, digits= 3)
mase.n.cr060.p14 <- mase(s.test_t$V1,n.cr060[[1]]$frc.out, step_size=1)
mae.n.cr065.p14 <- MAE(s.test_t$V1,n.cr065[[1]]$frc.out, digits= 3)
mse.n.cr065.p14 <- MSE(s.test_t$V1,n.cr065[[1]]$frc.out, digits= 3)
smape.n.cr065.p14 <- SMAPE(s.test_t$V1,n.cr065[[1]]$frc.out, digits= 3)
mase.n.cr065.p14 <- mase(s.test_t$V1,n.cr065[[1]]$frc.out, step_size=1)
mae.n.cr070.p14 <- MAE(s.test_t$V1,n.cr070[[1]]$frc.out, digits= 3)
mse.n.cr070.p14 <- MSE(s.test_t$V1,n.cr070[[1]]$frc.out, digits= 3)
smape.n.cr070.p14 <- SMAPE(s.test_t$V1,n.cr070[[1]]$frc.out, digits= 3)
mase.n.cr070.p14 <- mase(s.test_t$V1,n.cr070[[1]]$frc.out, step_size=1)
mae.n.cr075.p14 <- MAE(s.test_t$V1,n.cr075[[1]]$frc.out, digits= 3)
mse.n.cr075.p14 <- MSE(s.test_t$V1,n.cr075[[1]]$frc.out, digits= 3)
smape.n.cr075.p14 <- SMAPE(s.test_t$V1,n.cr075[[1]]$frc.out, digits= 3)
mase.n.cr075.p14 <- mase(s.test_t$V1,n.cr075[[1]]$frc.out, step_size=1)
mae.n.cr080.p14 <- MAE(s.test_t$V1,n.cr080[[1]]$frc.out, digits= 3)
mse.n.cr080.p14 <- MSE(s.test_t$V1,n.cr080[[1]]$frc.out, digits= 3)
smape.n.cr080.p14 <- SMAPE(s.test_t$V1,n.cr080[[1]]$frc.out, digits= 3)
mase.n.cr080.p14 <- mase(s.test_t$V1,n.cr080[[1]]$frc.out, step_size=1)
mae.n.cr085.p14 <- MAE(s.test_t$V1,n.cr085[[1]]$frc.out, digits= 3)
mse.n.cr085.p14 <- MSE(s.test_t$V1,n.cr085[[1]]$frc.out, digits= 3)
smape.n.cr085.p14 <- SMAPE(s.test_t$V1,n.cr085[[1]]$frc.out, digits= 3)
mase.n.cr085.p14 <- mase(s.test_t$V1,n.cr085[[1]]$frc.out, step_size=1)
mae.n.cr090.p14 <- MAE(s.test_t$V1,n.cr090[[1]]$frc.out, digits= 3)
mse.n.cr090.p14 <- MSE(s.test_t$V1,n.cr090[[1]]$frc.out, digits= 3)
smape.n.cr090.p14 <- SMAPE(s.test_t$V1,n.cr090[[1]]$frc.out, digits= 3)
mase.n.cr090.p14 <- mase(s.test_t$V1,n.cr090[[1]]$frc.out, step_size=1)
mae.n.cr095.p14 <- MAE(s.test_t$V1,n.cr095[[1]]$frc.out, digits= 3)
mse.n.cr095.p14 <- MSE(s.test_t$V1,n.cr095[[1]]$frc.out, digits= 3)
smape.n.cr095.p14 <- SMAPE(s.test_t$V1,n.cr095[[1]]$frc.out, digits= 3)
mase.n.cr095.p14 <- mase(s.test_t$V1,n.cr095[[1]]$frc.out, step_size=1)
mae.o.crmae1.p14 <- MAE(s.test_t$V1,o.crmae1[[1]]$frc.out, digits= 3)
mse.o.crmae1.p14 <- MSE(s.test_t$V1,o.crmae1[[1]]$frc.out, digits= 3)
smape.o.crmae1.p14 <- SMAPE(s.test_t$V1,o.crmae1[[1]]$frc.out, digits= 3)
mase.o.crmae1.p14 <- mase(s.test_t$V1,o.crmae1[[1]]$frc.out, step_size=1)
mae.o.crmae2.p14 <- MAE(s.test_t$V1,o.crmae2[[1]]$frc.out, digits= 3)
mse.o.crmae2.p14 <- MSE(s.test_t$V1,o.crmae2[[1]]$frc.out, digits= 3)
smape.o.crmae2.p14 <- SMAPE(s.test_t$V1,o.crmae2[[1]]$frc.out, digits= 3)
mase.o.crmae2.p14 <- mase(s.test_t$V1,o.crmae2[[1]]$frc.out, step_size=1)
mae.o.crmar1.p14 <- MAE(s.test_t$V1,o.crmar1[[1]]$frc.out, digits= 3)
mse.o.crmar1.p14 <- MSE(s.test_t$V1,o.crmar1[[1]]$frc.out, digits= 3)
smape.o.crmar1.p14 <- SMAPE(s.test_t$V1,o.crmar1[[1]]$frc.out, digits= 3)
mase.o.crmar1.p14 <- mase(s.test_t$V1,o.crmar1[[1]]$frc.out, step_size=1)
mae.o.crmar2.p14 <- MAE(s.test_t$V1,o.crmar2[[1]]$frc.out, digits= 3)
mse.o.crmar2.p14 <- MSE(s.test_t$V1,o.crmar2[[1]]$frc.out, digits= 3)
smape.o.crmar2.p14 <- SMAPE(s.test_t$V1,o.crmar2[[1]]$frc.out, digits= 3)
mase.o.crmar2.p14 <- mase(s.test_t$V1,o.crmar2[[1]]$frc.out, step_size=1)
mae.o.crmse1.p14 <- MAE(s.test_t$V1,o.crmse1[[1]]$frc.out, digits= 3)
mse.o.crmse1.p14 <- MSE(s.test_t$V1,o.crmse1[[1]]$frc.out, digits= 3)
smape.o.crmse1.p14 <- SMAPE(s.test_t$V1,o.crmse1[[1]]$frc.out, digits= 3)
mase.o.crmse1.p14 <- mase(s.test_t$V1,o.crmse1[[1]]$frc.out, step_size=1)
mae.o.crmse2.p14 <- MAE(s.test_t$V1,o.crmse2[[1]]$frc.out, digits= 3)
mse.o.crmse2.p14 <- MSE(s.test_t$V1,o.crmse2[[1]]$frc.out, digits= 3)
smape.o.crmse2.p14 <- SMAPE(s.test_t$V1,o.crmse2[[1]]$frc.out, digits= 3)
mase.o.crmse2.p14 <- mase(s.test_t$V1,o.crmse2[[1]]$frc.out, step_size=1)
mae.o.crmsr1.p14 <- MAE(s.test_t$V1,o.crmsr1[[1]]$frc.out, digits= 3)
mse.o.crmsr1.p14 <- MSE(s.test_t$V1,o.crmsr1[[1]]$frc.out, digits= 3)
smape.o.crmsr1.p14 <- SMAPE(s.test_t$V1,o.crmsr1[[1]]$frc.out, digits= 3)
mase.o.crmsr1.p14 <- mase(s.test_t$V1,o.crmsr1[[1]]$frc.out, step_size=1)
mae.o.crmsr2.p14 <- MAE(s.test_t$V1,o.crmsr2[[1]]$frc.out, digits= 3)
mse.o.crmsr2.p14 <- MSE(s.test_t$V1,o.crmsr2[[1]]$frc.out, digits= 3)

res.cr.p14 <- rbind(mae.m.cr005.p14,    mse.m.cr005.p14,    smape.m.cr005.p14,  mase.m.cr005.p14,   mae.m.cr010.p14,    mse.m.cr010.p14,    smape.m.cr010.p14,  mase.m.cr010.p14,   mae.m.cr015.p14,    mse.m.cr015.p14,    smape.m.cr015.p14,  mase.m.cr015.p14,   mae.m.cr020.p14,    mse.m.cr020.p14,    smape.m.cr020.p14,  mase.m.cr020.p14,   mae.m.cr025.p14,    mse.m.cr025.p14,    smape.m.cr025.p14,  mase.m.cr025.p14,   mae.m.cr030.p14,    mse.m.cr030.p14,    smape.m.cr030.p14,  mase.m.cr030.p14,   mae.m.cr035.p14,    mse.m.cr035.p14,    smape.m.cr035.p14,  mase.m.cr035.p14,   mae.m.cr040.p14,    mse.m.cr040.p14,    smape.m.cr040.p14,  mase.m.cr040.p14,   mae.m.cr045.p14,    mse.m.cr045.p14,    smape.m.cr045.p14,  mase.m.cr045.p14,   mae.m.cr050.p14,    mse.m.cr050.p14,    smape.m.cr050.p14,  mase.m.cr050.p14,   mae.m.cr055.p14,    mse.m.cr055.p14,    smape.m.cr055.p14,  mase.m.cr055.p14,   mae.m.cr060.p14,    mse.m.cr060.p14,    smape.m.cr060.p14,  mase.m.cr060.p14,   mae.m.cr065.p14,    mse.m.cr065.p14,    smape.m.cr065.p14,  mase.m.cr065.p14,   mae.m.cr070.p14,    mse.m.cr070.p14,    smape.m.cr070.p14,  mase.m.cr070.p14,   mae.m.cr075.p14,    mse.m.cr075.p14,    smape.m.cr075.p14,  mase.m.cr075.p14,   mae.m.cr080.p14,    mse.m.cr080.p14,    smape.m.cr080.p14,  mase.m.cr080.p14,   mae.m.cr085.p14,    mse.m.cr085.p14,    smape.m.cr085.p14,  mase.m.cr085.p14,   mae.m.cr090.p14,    mse.m.cr090.p14,    smape.m.cr090.p14,  mase.m.cr090.p14,   mae.m.cr095.p14,    mse.m.cr095.p14,    smape.m.cr095.p14,  mase.m.cr095.p14,   mae.n.cr005.p14,    mse.n.cr005.p14,    smape.n.cr005.p14,  mase.n.cr005.p14,   mae.n.cr010.p14,    mse.n.cr010.p14,    smape.n.cr010.p14,  mase.n.cr010.p14,   mae.n.cr015.p14,    mse.n.cr015.p14,    smape.n.cr015.p14,  mase.n.cr015.p14,   mae.n.cr020.p14,    mse.n.cr020.p14,    smape.n.cr020.p14,  mase.n.cr020.p14,   mae.n.cr025.p14,    mse.n.cr025.p14,    smape.n.cr025.p14,  mase.n.cr025.p14,   mae.n.cr030.p14,    mse.n.cr030.p14,    smape.n.cr030.p14,  mase.n.cr030.p14,   mae.n.cr035.p14,    mse.n.cr035.p14,    smape.n.cr035.p14,  mase.n.cr035.p14,   mae.n.cr040.p14,    mse.n.cr040.p14,    smape.n.cr040.p14,  mase.n.cr040.p14,   mae.n.cr045.p14,    mse.n.cr045.p14,    smape.n.cr045.p14,  mase.n.cr045.p14,   mae.n.cr050.p14,    mse.n.cr050.p14,    smape.n.cr050.p14,  mase.n.cr050.p14,   mae.n.cr055.p14,    mse.n.cr055.p14,    smape.n.cr055.p14,  mase.n.cr055.p14,   mae.n.cr060.p14,    mse.n.cr060.p14,    smape.n.cr060.p14,  mase.n.cr060.p14,   mae.n.cr065.p14,    mse.n.cr065.p14,    smape.n.cr065.p14,  mase.n.cr065.p14,   mae.n.cr070.p14,    mse.n.cr070.p14,    smape.n.cr070.p14,  mase.n.cr070.p14,   mae.n.cr075.p14,    mse.n.cr075.p14,    smape.n.cr075.p14,  mase.n.cr075.p14,   mae.n.cr080.p14,    mse.n.cr080.p14,    smape.n.cr080.p14,  mase.n.cr080.p14,   mae.n.cr085.p14,    mse.n.cr085.p14,    smape.n.cr085.p14,  mase.n.cr085.p14,   mae.n.cr090.p14,    mse.n.cr090.p14,    smape.n.cr090.p14,  mase.n.cr090.p14,   mae.n.cr095.p14,    mse.n.cr095.p14,    smape.n.cr095.p14,  mase.n.cr095.p14,   mae.o.crmae1.p14,   mse.o.crmae1.p14,   smape.o.crmae1.p14, mase.o.crmae1.p14,  mae.o.crmae2.p14,   mse.o.crmae2.p14,   smape.o.crmae2.p14, mase.o.crmae2.p14,  mae.o.crmar1.p14,   mse.o.crmar1.p14,   smape.o.crmar1.p14, mase.o.crmar1.p14,  mae.o.crmar2.p14,   mse.o.crmar2.p14,   smape.o.crmar2.p14, mase.o.crmar2.p14,  mae.o.crmse1.p14,   mse.o.crmse1.p14,   smape.o.crmse1.p14, mase.o.crmse1.p14,  mae.o.crmse2.p14,   mse.o.crmse2.p14,   smape.o.crmse2.p14, mase.o.crmse2.p14,  mae.o.crmsr1.p14,   mse.o.crmsr1.p14,   smape.o.crmsr1.p14, mase.o.crmsr1.p14,  mae.o.crmsr2.p14,   mse.o.crmsr2.p14,   smape.o.crmsr2.p14, mase.o.crmsr2.p14)

我想用一种较短的方法来计算精度函数,并建立一个表来显示所有参数的精度。

非常感谢您的帮助。

0 个答案:

没有答案