| Classical Decomposition - Additive | *The author of this computation has been verified* | R Software Module: /rwasp_decompose.wasp (opens new window with default values) | Title produced by software: Classical Decomposition | Date of computation: Sun, 12 Dec 2010 11:03:52 +0000 | | Cite this page as follows: | Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL http://www.freestatistics.org/blog/date/2010/Dec/12/t12921517316pksus1i5l63l37.htm/, Retrieved Sun, 12 Dec 2010 12:02:15 +0100 | | BibTeX entries for LaTeX users: | @Manual{KEY,
author = {{YOUR NAME}},
publisher = {Office for Research Development and Education},
title = {Statistical Computations at FreeStatistics.org, URL http://www.freestatistics.org/blog/date/2010/Dec/12/t12921517316pksus1i5l63l37.htm/},
year = {2010},
}
@Manual{R,
title = {R: A Language and Environment for Statistical Computing},
author = {{R Development Core Team}},
organization = {R Foundation for Statistical Computing},
address = {Vienna, Austria},
year = {2010},
note = {{ISBN} 3-900051-07-0},
url = {http://www.R-project.org},
}
| | Original text written by user: | | | IsPrivate? | No (this computation is public) | | User-defined keywords: | | | Dataseries X: | » Textbox « » Textfile « » CSV « | 43880
43110
44496
44164
40399
36763
37903
35532
35533
32110
33374
35462
33508
36080
34560
38737
38144
37594
36424
36843
37246
38661
40454
44928
48441
48140
45998
47369
49554
47510
44873
45344
42413
36912
43452
42142
44382
43636
44167
44423
42868
43908
42013
38846
35087
33026
34646
37135
37985
43121
43722
43630
42234
39351
39327
35704
30466
28155
29257
29998
32529
34787
33855
34556
31348
30805
28353
24514
21106
21346
23335
24379
26290
30084
29429
30632
27349
27264
27474
24482
21453
18788
19282
19713
21917
23812
23785
24696
24562
23580
24939
23899
21454
19761
19815
20780
23462
25005
24725
26198
27543
26471
26558
25317
22896
22248
23406
25073
27691
30599
31948
32946
34012
32936
32974
30951
29812
29010
31068
32447
34844
35676
35387
36488
35652
33488
32914
29781
27951 | | Output produced by software: |
Classical Decomposition by Moving Averages | t | Observations | Fit | Trend | Seasonal | Random | 1 | 43880 | NA | NA | 224.824845679014 | NA | 2 | 43110 | NA | NA | 2386.51929012346 | NA | 3 | 44496 | NA | NA | 2092.54706790123 | NA | 4 | 44164 | NA | NA | 3355.3850308642 | NA | 5 | 40399 | NA | NA | 2761.19058641975 | NA | 6 | 36763 | NA | NA | 1875.26929012346 | NA | 7 | 37903 | 39290.9313271605 | 38128.3333333333 | 1162.59799382716 | -1387.93132716049 | 8 | 35532 | 36668.7554012346 | 37403.25 | -734.494598765433 | -1136.75540123456 | 9 | 35533 | 33296.8804012346 | 36696.3333333333 | -3399.45293209877 | 2236.11959876544 | 10 | 32110 | 31104.8942901234 | 36056.2083333333 | -4951.31404320988 | 1005.10570987655 | 11 | 33374 | 32674.3155864197 | 35736.125 | -3061.80941358025 | 699.684413580253 | 12 | 35462 | 33965.5285493827 | 35676.7916666667 | -1711.26311728395 | 1496.47145061728 | 13 | 33508 | 35874.6165123457 | 35649.7916666667 | 224.824845679014 | -2366.61651234568 | 14 | 36080 | 38029.3109567901 | 35642.7916666667 | 2386.51929012346 | -1949.31095679012 | 15 | 34560 | 37861.3387345679 | 35768.7916666667 | 2092.54706790123 | -3301.3387345679 | 16 | 38737 | 39468.5100308642 | 36113.125 | 3355.3850308642 | -731.5100308642 | 17 | 38144 | 39442.2739197531 | 36681.0833333333 | 2761.19058641975 | -1298.27391975309 | 18 | 37594 | 39245.7692901235 | 37370.5 | 1875.26929012346 | -1651.76929012345 | 19 | 36424 | 39549.7229938272 | 38387.125 | 1162.59799382716 | -3125.72299382716 | 20 | 36843 | 38777.3387345679 | 39511.8333333333 | -734.494598765433 | -1934.3387345679 | 21 | 37246 | 37091.4637345679 | 40490.9166666667 | -3399.45293209877 | 154.536265432100 | 22 | 38661 | 36375.8526234568 | 41327.1666666667 | -4951.31404320988 | 2285.14737654321 | 23 | 40454 | 39100.4405864198 | 42162.25 | -3061.80941358025 | 1353.55941358024 | 24 | 44928 | 41339.5702160494 | 43050.8333333333 | -1711.26311728395 | 3588.42978395061 | 25 | 48441 | 44040.8665123457 | 43816.0416666667 | 224.824845679014 | 4400.13348765432 | 26 | 48140 | 46908.8109567901 | 44522.2916666667 | 2386.51929012346 | 1231.18904320987 | 27 | 45998 | 47184.3387345679 | 45091.7916666667 | 2092.54706790123 | -1186.3387345679 | 28 | 47369 | 48589.5933641975 | 45234.2083333333 | 3355.3850308642 | -1220.59336419754 | 29 | 49554 | 48047.4405864198 | 45286.25 | 2761.19058641975 | 1506.55941358025 | 30 | 47510 | 47170.3526234568 | 45295.0833333333 | 1875.26929012346 | 339.647376543217 | 31 | 44873 | 46172.4729938272 | 45009.875 | 1162.59799382716 | -1299.47299382716 | 32 | 45344 | 43918.5887345679 | 44653.0833333333 | -734.494598765433 | 1425.4112654321 | 33 | 42413 | 40989.6720679012 | 44389.125 | -3399.45293209877 | 1423.32793209876 | 34 | 36912 | 39238.7692901235 | 44190.0833333333 | -4951.31404320988 | -2326.76929012346 | 35 | 43452 | 40726.9405864197 | 43788.75 | -3061.80941358025 | 2725.05941358025 | 36 | 42142 | 41648.8202160494 | 43360.0833333333 | -1711.26311728395 | 493.179783950618 | 37 | 44382 | 43315.6581790123 | 43090.8333333333 | 224.824845679014 | 1066.34182098765 | 38 | 43636 | 45087.4359567901 | 42700.9166666667 | 2386.51929012346 | -1451.43595679012 | 39 | 44167 | 44217.4637345679 | 42124.9166666667 | 2092.54706790123 | -50.4637345679002 | 40 | 44423 | 45013.1350308642 | 41657.75 | 3355.3850308642 | -590.1350308642 | 41 | 42868 | 43890.1072530864 | 41128.9166666667 | 2761.19058641975 | -1022.10725308642 | 42 | 43908 | 42428.6442901234 | 40553.375 | 1875.26929012346 | 1479.35570987655 | 43 | 42013 | 41240.8063271605 | 40078.2083333333 | 1162.59799382716 | 772.193672839501 | 44 | 38846 | 39055.7137345679 | 39790.2083333333 | -734.494598765433 | -209.713734567893 | 45 | 35087 | 36350.7554012346 | 39750.2083333333 | -3399.45293209877 | -1263.75540123456 | 46 | 33026 | 34747.3109567901 | 39698.625 | -4951.31404320988 | -1721.31095679013 | 47 | 34646 | 36577.3572530864 | 39639.1666666667 | -3061.80941358025 | -1931.35725308642 | 48 | 37135 | 37711.6118827161 | 39422.875 | -1711.26311728395 | -576.611882716054 | 49 | 37985 | 39345.9081790123 | 39121.0833333333 | 224.824845679014 | -1360.90817901235 | 50 | 43121 | 41264.7692901235 | 38878.25 | 2386.51929012346 | 1856.23070987655 | 51 | 43722 | 40647.3387345679 | 38554.7916666667 | 2092.54706790123 | 3074.6612654321 | 52 | 43630 | 41514.6766975309 | 38159.2916666667 | 3355.3850308642 | 2115.32330246914 | 53 | 42234 | 40492.9822530864 | 37731.7916666667 | 2761.19058641975 | 1741.01774691357 | 54 | 39351 | 39085.1442901234 | 37209.875 | 1875.26929012346 | 265.855709876552 | 55 | 39327 | 37847.7646604938 | 36685.1666666667 | 1162.59799382716 | 1479.23533950617 | 56 | 35704 | 35376.0887345679 | 36110.5833333333 | -734.494598765433 | 327.9112654321 | 57 | 30466 | 31952.7554012346 | 35352.2083333333 | -3399.45293209877 | -1486.75540123456 | 58 | 28155 | 29611.6859567901 | 34563 | -4951.31404320988 | -1456.68595679012 | 59 | 29257 | 30669.5239197531 | 33731.3333333333 | -3061.80941358025 | -1412.52391975308 | 60 | 29998 | 31210.4035493827 | 32921.6666666667 | -1711.26311728395 | -1212.40354938271 | 61 | 32529 | 32333.1581790123 | 32108.3333333333 | 224.824845679014 | 195.841820987658 | 62 | 34787 | 33571.3526234568 | 31184.8333333333 | 2386.51929012346 | 1215.64737654322 | 63 | 33855 | 32421.1304012346 | 30328.5833333333 | 2092.54706790123 | 1433.86959876543 | 64 | 34556 | 33010.2600308642 | 29654.875 | 3355.3850308642 | 1545.73996913580 | 65 | 31348 | 31885.6072530864 | 29124.4166666667 | 2761.19058641975 | -537.607253086418 | 66 | 30805 | 30518.8109567901 | 28643.5416666667 | 1875.26929012346 | 286.189043209873 | 67 | 28353 | 29312.0563271605 | 28149.4583333333 | 1162.59799382716 | -959.056327160495 | 68 | 24514 | 26959.0470679012 | 27693.5416666667 | -734.494598765433 | -2445.04706790123 | 69 | 21106 | 23913.7137345679 | 27313.1666666667 | -3399.45293209877 | -2807.71373456790 | 70 | 21346 | 22013.9359567901 | 26965.25 | -4951.31404320988 | -667.935956790119 | 71 | 23335 | 23573.3155864198 | 26635.125 | -3061.80941358025 | -238.315586419751 | 72 | 24379 | 24609.6952160494 | 26320.9583333333 | -1711.26311728395 | -230.695216049382 | 73 | 26290 | 26361.6165123457 | 26136.7916666667 | 224.824845679014 | -71.616512345674 | 74 | 30084 | 28485.3526234568 | 26098.8333333333 | 2386.51929012346 | 1598.64737654322 | 75 | 29429 | 28204.5054012346 | 26111.9583333333 | 2092.54706790123 | 1224.49459876544 | 76 | 30632 | 29375.2183641975 | 26019.8333333333 | 3355.3850308642 | 1256.78163580247 | 77 | 27349 | 28505.5655864197 | 25744.375 | 2761.19058641975 | -1156.56558641975 | 78 | 27264 | 27256.3526234568 | 25381.0833333333 | 1875.26929012346 | 7.64737654320561 | 79 | 27474 | 26167.0563271605 | 25004.4583333333 | 1162.59799382716 | 1306.94367283950 | 80 | 24482 | 23826.4220679012 | 24560.9166666667 | -734.494598765433 | 655.577932098764 | 81 | 21453 | 20664.9637345679 | 24064.4166666667 | -3399.45293209877 | 788.0362654321 | 82 | 18788 | 18630.6026234568 | 23581.9166666667 | -4951.31404320988 | 157.397376543213 | 83 | 19282 | 20156.6489197531 | 23218.4583333333 | -3061.80941358025 | -874.64891975309 | 84 | 19713 | 21237.5702160494 | 22948.8333333333 | -1711.26311728395 | -1524.57021604938 | 85 | 21917 | 22914.5331790123 | 22689.7083333333 | 224.824845679014 | -997.53317901235 | 86 | 23812 | 24946.3109567901 | 22559.7916666667 | 2386.51929012346 | -1134.31095679012 | 87 | 23785 | 24628.0887345679 | 22535.5416666667 | 2092.54706790123 | -843.088734567904 | 88 | 24696 | 25931.5100308642 | 22576.125 | 3355.3850308642 | -1235.5100308642 | 89 | 24562 | 25400.0655864198 | 22638.875 | 2761.19058641975 | -838.065586419754 | 90 | 23580 | 24580.8109567901 | 22705.5416666667 | 1875.26929012346 | -1000.81095679013 | 91 | 24939 | 23976.9729938272 | 22814.375 | 1162.59799382716 | 962.027006172844 | 92 | 23899 | 22193.9637345679 | 22928.4583333333 | -734.494598765433 | 1705.0362654321 | 93 | 21454 | 19617.8804012346 | 23017.3333333333 | -3399.45293209877 | 1836.11959876543 | 94 | 19761 | 18167.7692901235 | 23119.0833333333 | -4951.31404320988 | 1593.23070987655 | 95 | 19815 | 20244.0655864198 | 23305.875 | -3061.80941358025 | -429.065586419754 | 96 | 20780 | 21839.2785493827 | 23550.5416666667 | -1711.26311728395 | -1059.27854938271 | 97 | 23462 | 23963.2831790123 | 23738.4583333333 | 224.824845679014 | -501.283179012342 | 98 | 25005 | 26251.5192901235 | 23865 | 2386.51929012346 | -1246.51929012345 | 99 | 24725 | 26076.7137345679 | 23984.1666666667 | 2092.54706790123 | -1351.71373456790 | 100 | 26198 | 27503.2600308642 | 24147.875 | 3355.3850308642 | -1305.2600308642 | 101 | 27543 | 27162.3155864198 | 24401.125 | 2761.19058641975 | 380.684413580249 | 102 | 26471 | 26604.8942901235 | 24729.625 | 1875.26929012346 | -133.894290123459 | 103 | 26558 | 26247.3063271605 | 25084.7083333333 | 1162.59799382716 | 310.693672839509 | 104 | 25317 | 24759.5054012346 | 25494 | -734.494598765433 | 557.494598765432 | 105 | 22896 | 22628.5887345679 | 26028.0416666667 | -3399.45293209877 | 267.411265432096 | 106 | 22248 | 21658.8526234568 | 26610.1666666667 | -4951.31404320988 | 589.147376543209 | 107 | 23406 | 24099.0655864198 | 27160.875 | -3061.80941358025 | -693.065586419754 | 108 | 25073 | 25988.5285493827 | 27699.7916666667 | -1711.26311728395 | -915.528549382718 | 109 | 27691 | 28461.324845679 | 28236.5 | 224.824845679014 | -770.324845679013 | 110 | 30599 | 31125.1026234568 | 28738.5833333333 | 2386.51929012346 | -526.102623456787 | 111 | 31948 | 31354.0470679012 | 29261.5 | 2092.54706790123 | 593.952932098764 | 112 | 32946 | 33186.8016975309 | 29831.4166666667 | 3355.3850308642 | -240.801697530864 | 113 | 34012 | 33193.6072530864 | 30432.4166666667 | 2761.19058641975 | 818.392746913585 | 114 | 32936 | 32934.1859567901 | 31058.9166666667 | 1875.26929012346 | 1.81404320987713 | 115 | 32974 | 32826.8063271605 | 31664.2083333333 | 1162.59799382716 | 147.193672839509 | 116 | 30951 | 31439.2970679012 | 32173.7916666667 | -734.494598765433 | -488.297067901229 | 117 | 29812 | 29129.1720679012 | 32528.625 | -3399.45293209877 | 682.827932098764 | 118 | 29010 | 27868.1859567901 | 32819.5 | -4951.31404320988 | 1141.81404320987 | 119 | 31068 | 29973.6072530864 | 33035.4166666667 | -3061.80941358025 | 1094.39274691358 | 120 | 32447 | 31415.4868827160 | 33126.75 | -1711.26311728395 | 1031.51311728395 | 121 | 34844 | NA | 33147.25 | NA | NA | 122 | 35676 | NA | 33096 | NA | NA | 123 | 35387 | NA | 32969.7083333333 | NA | NA | 124 | 36488 | NA | NA | NA | NA | 125 | 35652 | NA | NA | NA | NA | 126 | 33488 | NA | NA | NA | NA | 127 | 32914 | NA | NA | NA | NA | 128 | 29781 | NA | NA | NA | NA | 129 | 27951 | NA | NA | NA | NA |
| | Charts produced by software: | | http://www.freestatistics.org/blog/date/2010/Dec/12/t12921517316pksus1i5l63l37/1gs651292151828.png (open in new window) | http://www.freestatistics.org/blog/date/2010/Dec/12/t12921517316pksus1i5l63l37/1gs651292151828.ps (open in new window) |
| http://www.freestatistics.org/blog/date/2010/Dec/12/t12921517316pksus1i5l63l37/2gs651292151828.png (open in new window) | http://www.freestatistics.org/blog/date/2010/Dec/12/t12921517316pksus1i5l63l37/2gs651292151828.ps (open in new window) |
| http://www.freestatistics.org/blog/date/2010/Dec/12/t12921517316pksus1i5l63l37/3q15q1292151828.png (open in new window) | http://www.freestatistics.org/blog/date/2010/Dec/12/t12921517316pksus1i5l63l37/3q15q1292151828.ps (open in new window) |
| http://www.freestatistics.org/blog/date/2010/Dec/12/t12921517316pksus1i5l63l37/41b5t1292151828.png (open in new window) | http://www.freestatistics.org/blog/date/2010/Dec/12/t12921517316pksus1i5l63l37/41b5t1292151828.ps (open in new window) |
| | Parameters (Session): | par1 = additive ; par2 = 12 ; | | Parameters (R input): | par1 = additive ; par2 = 12 ; | | R code (references can be found in the software module): | 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])
a<-table.element(a,m$trend[i]+m$seasonal[i])
a<-table.element(a,m$trend[i])
a<-table.element(a,m$seasonal[i])
a<-table.element(a,m$random[i])
a<-table.row.end(a)
}
a<-table.end(a)
table.save(a,file='mytable.tab')
| |
Copyright
This work is licensed under a
Creative Commons Attribution-Noncommercial-Share Alike 3.0 License.
Software written by Ed van Stee & Patrick Wessa
Disclaimer
Information provided on this web site is provided
"AS IS" without warranty of any kind, either express or implied,
including, without limitation, warranties of merchantability, fitness
for a particular purpose, and noninfringement. We use reasonable
efforts to include accurate and timely information and periodically
update the information, and software without notice. However, we make
no warranties or representations as to the accuracy or
completeness of such information (or software), and we assume no
liability or responsibility for errors or omissions in the content of
this web site, or any software bugs in online applications. Your use of
this web site is AT YOUR OWN RISK. Under no circumstances and under no
legal theory shall we be liable to you or any other person
for any direct, indirect, special, incidental, exemplary, or
consequential damages arising from your access to, or use of, this web
site.
Privacy Policy
We may request personal information to be submitted to our servers in order to be able to:
- personalize online software applications according to your needs
- enforce strict security rules with respect to the data that you upload (e.g. statistical data)
- manage user sessions of online applications
- alert you about important changes or upgrades in resources or applications
We NEVER allow other companies to directly offer registered users
information about their products and services. Banner references and
hyperlinks of third parties NEVER contain any personal data of the
visitor.
We do NOT sell, nor transmit by any means, personal information, nor statistical data series uploaded by you to third parties.
We carefully protect your data from loss, misuse, alteration,
and destruction. However, at any time, and under any circumstance you
are solely responsible for managing your passwords, and keeping them
secret.
We store a unique ANONYMOUS USER ID in the form of a small
'Cookie' on your computer. This allows us to track your progress when
using this website which is necessary to create state-dependent
features. The cookie is used for NO OTHER PURPOSE. At any time you may
opt to disallow cookies from this website - this will not affect other
features of this website.
We examine cookies that are used by third-parties (banner and
online ads) very closely: abuse from third-parties automatically
results in termination of the advertising contract without refund. We
have very good reason to believe that the cookies that are produced by
third parties (banner ads) do NOT cause any privacy or security risk.
FreeStatistics.org is safe. There is no need to download any
software to use the applications and services contained in this
website. Hence, your system's security is not compromised by their use,
and your personal data - other than data you submit in the account
application form, and the user-agent information that is transmitted by
your browser - is never transmitted to our servers.
As a general rule, we do not log on-line behavior of
individuals (other than normal logging of webserver 'hits'). However,
in cases of abuse, hacking, unauthorized access, Denial of Service
attacks, illegal copying, hotlinking, non-compliance with international
webstandards (such as robots.txt), or any other harmful behavior, our
system engineers are empowered to log, track, identify, publish, and
ban misbehaving individuals - even if this leads to ban entire blocks
of IP addresses, or disclosing user's identity.
FreeStatistics.org is powered by
|