Send output to:
Browser Blue - Charts White
Browser Black/White
CSV
Data:
5483.5 5386.2 5781.8 5137.4 5001.7 5123.8 5340 5696.4 5544.7 5747.6 5487.4 5590.1 5571.9 5363.1 6014.1 5480.4 5907.5 5772.2 5620 6614.7 6294.7 5938.3 5722.6 5595.6 5569.5 5753.7 5838.8 5401.1 6013.9 5461.1 5176.3 5916.5 5519.5 5873.9 5663.8 5339 5671.2 5741 5881.3 5531.2 5811.2 5391.4 5461.2 6091.3 5951 6511.7 6371.4 5601.2 6001.2 5920.7 5455.2 5703.8 5863 5762.9 5997.8 6542.7 6594.5 6915.1 6584.6 6412.2 5930.1 6022.3 6268.6 6179.9 6608.6 6424 6230.8 6628.2 6576.2 6947 6672.8 6249.9 5964.2 5840.1 6115.2 5800.5 6566.6 6377.3 6355.2 6999.3 6603.7 6998.3 6966.2 6383.3 5960 5682.1 5640.2 5694.1 6392.4 5835.3 6075.6 7387.1 6632.6 7048.1 6792.1 6094 6408.3 6492.1 6596.8 6078.2 6297.3 5960.8 6125.1 7253.4 6505.8 7419.5 7308.2 6373.1 6667.4 6518.6 6324.8 6764.1 6985 6091.5 6526 7116.9 6770.3 7221.9 7344.5 6565.6 6577.3 6597.8 6560.6 6729.2 6703.2 6716.1
Type of Seasonality
additive
additive
multiplicative
Seasonal Period
12
12
1
2
3
4
5
6
7
8
9
10
11
12
Chart options
R Code
par2 <- as.numeric(par2) x <- ts(x,freq=par2) m <- decompose(x,type=par1) m$figure bitmap(file='test1.png') plot(m) dev.off() mylagmax <- length(x)/2 bitmap(file='test2.png') op <- par(mfrow = c(2,2)) acf(as.numeric(x),lag.max = mylagmax,main='Observed') acf(as.numeric(m$trend),na.action=na.pass,lag.max = mylagmax,main='Trend') acf(as.numeric(m$seasonal),na.action=na.pass,lag.max = mylagmax,main='Seasonal') acf(as.numeric(m$random),na.action=na.pass,lag.max = mylagmax,main='Random') par(op) dev.off() bitmap(file='test3.png') op <- par(mfrow = c(2,2)) spectrum(as.numeric(x),main='Observed') spectrum(as.numeric(m$trend[!is.na(m$trend)]),main='Trend') spectrum(as.numeric(m$seasonal[!is.na(m$seasonal)]),main='Seasonal') spectrum(as.numeric(m$random[!is.na(m$random)]),main='Random') par(op) dev.off() bitmap(file='test4.png') op <- par(mfrow = c(2,2)) cpgram(as.numeric(x),main='Observed') cpgram(as.numeric(m$trend[!is.na(m$trend)]),main='Trend') cpgram(as.numeric(m$seasonal[!is.na(m$seasonal)]),main='Seasonal') cpgram(as.numeric(m$random[!is.na(m$random)]),main='Random') par(op) dev.off() load(file='createtable') a<-table.start() a<-table.row.start(a) a<-table.element(a,'Classical Decomposition by Moving Averages',6,TRUE) a<-table.row.end(a) a<-table.row.start(a) a<-table.element(a,'t',header=TRUE) a<-table.element(a,'Observations',header=TRUE) a<-table.element(a,'Fit',header=TRUE) a<-table.element(a,'Trend',header=TRUE) a<-table.element(a,'Seasonal',header=TRUE) a<-table.element(a,'Random',header=TRUE) a<-table.row.end(a) for (i in 1:length(m$trend)) { a<-table.row.start(a) a<-table.element(a,i,header=TRUE) a<-table.element(a,x[i]) if (par1 == 'additive') a<-table.element(a,signif(m$trend[i]+m$seasonal[i],6)) else a<-table.element(a,signif(m$trend[i]*m$seasonal[i],6)) a<-table.element(a,signif(m$trend[i],6)) a<-table.element(a,signif(m$seasonal[i],6)) a<-table.element(a,signif(m$random[i],6)) a<-table.row.end(a) } a<-table.end(a) table.save(a,file='mytable.tab')
Compute
Summary of computational transaction
Raw Input
view raw input (R code)
Raw Output
view raw output of R engine
Computing time
0 seconds
R Server
Big Analytics Cloud Computing Center
Click here to blog (archive) this computation