Free Statistics

of Irreproducible Research!

Author's title

Author*Unverified author*
R Software Modulerwasp_decompose.wasp
Title produced by softwareClassical Decomposition
Date of computationWed, 23 Nov 2016 19:58:42 +0000
Cite this page as followsStatistical Computations at FreeStatistics.org, Office for Research Development and Education, URL https://freestatistics.org/blog/index.php?v=date/2016/Nov/23/t1479931148m8jprpx2ub2efcs.htm/, Retrieved Tue, 07 May 2024 02:38:55 +0200
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL https://freestatistics.org/blog/index.php?pk=, Retrieved Tue, 07 May 2024 02:38:55 +0200
QR Codes:

Original text written by user:
IsPrivate?No (this computation is public)
User-defined keywords
Estimated Impact0
Dataseries X:
28886
28549
33348
29017
30924
30435
29431
30290
31286
30622
31742
30391
30740
32086
33947
31312
33239
32362
32170
32665
31412
34891
33919
30706
32846
31368
33130
31665
33139
32201
32230
30287
31918
33853
32232
31484
31902
30260
32823
32018
32100
31952
33274
29491
32751
33643
31226
30976
28880
29325
34923
32642
31487
33832
32724
29545
32338
32743
32231
32536




Summary of computational transaction
Raw Inputview raw input (R code)
Raw Outputview raw output of R engine
Computing time2 seconds
R Server'George Udny Yule' @ yule.wessa.net

\begin{tabular}{lllllllll}
\hline
Summary of computational transaction \tabularnewline
Raw Input & view raw input (R code)  \tabularnewline
Raw Output & view raw output of R engine  \tabularnewline
Computing time & 2 seconds \tabularnewline
R Server & 'George Udny Yule' @ yule.wessa.net \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=&T=0

[TABLE]
[ROW][C]Summary of computational transaction[/C][/ROW]
[ROW][C]Raw Input[/C][C]view raw input (R code) [/C][/ROW]
[ROW][C]Raw Output[/C][C]view raw output of R engine [/C][/ROW]
[ROW][C]Computing time[/C][C]2 seconds[/C][/ROW]
[ROW][C]R Server[/C][C]'George Udny Yule' @ yule.wessa.net[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=&T=0

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=&T=0

As an alternative you can also use a QR Code:  

The GUIDs for individual cells are displayed in the table below:

Summary of computational transaction
Raw Inputview raw input (R code)
Raw Outputview raw output of R engine
Computing time2 seconds
R Server'George Udny Yule' @ yule.wessa.net







Classical Decomposition by Moving Averages
tObservationsFitTrendSeasonalRandom
128886NANA-904.596NA
228549NANA-1263.39NA
333348NANA1679.41NA
429017NANA-150.138NA
530924NANA404.674NA
630435NANA472.737NA
72943130508.230487.320.8932-1077.23
83029029631.830712-1080.13658.169
93128630938.230884.353.8828347.826
103062232415.131004.91410.22-1793.09
11317423159131197394.091150.951
12303913033631373.7-1037.6654.9505
133074030663.531568.1-904.59676.4714
143208630517.831781.2-1263.391568.18
153394733564.831885.41679.41382.169
163131231918.432068.5-150.138-606.404
173323932741.832337.1404.674497.201
183236232913.732441472.737-551.695
193217032562.732541.820.8932-392.727
203266531519.532599.7-1080.131145.46
213141232589.632535.753.8828-1177.59
223489133926.632516.41410.22964.409
23339193292132526.9394.091997.992
243070631478.432516-1037.66-772.383
253284631607.232511.8-904.5961238.76
263136831151.932415.2-1263.39216.138
273313034016.732337.21679.41-886.664
283166532164.932315.1-150.138-499.945
293313932606.232201.5404.674532.784
303220132636.432163.7472.737-435.404
313223032177.632156.720.893252.3568
323028730991.132071.2-1080.13-704.122
333191832066.232012.353.8828-148.174
343385333424.432014.21410.22428.576
353223232379.731985.6394.091-147.716
363148430894.331932-1037.66589.701
373190231060.531965.1-904.596841.513
38302603071231975.4-1263.39-452.029
393282333656.4319771679.41-833.372
403201831852.832002.9-150.138165.221
413210032356.931952.3404.674-256.924
423195232361.931889.2472.737-409.904
43332743176331742.120.89321511.02
442949130497.131577.2-1080.13-1006.08
453275131679.631625.853.88281071.37
463364333149.531739.21410.22493.534
473122632133.831739.7394.091-907.799
483097630754.831792.5-1037.66221.159
492888030943.331847.9-904.596-2063.32
502932530563.931827.2-1263.39-1238.86
513492333491.731812.31679.411431.29
523264231607.431757.6-150.1381034.55
533148732166.631762404.674-679.633
543383232341.631868.8472.7371490.43
5532724NANA20.8932NA
5629545NANA-1080.13NA
5732338NANA53.8828NA
5832743NANA1410.22NA
5932231NANA394.091NA
6032536NANA-1037.66NA

\begin{tabular}{lllllllll}
\hline
Classical Decomposition by Moving Averages \tabularnewline
t & Observations & Fit & Trend & Seasonal & Random \tabularnewline
1 & 28886 & NA & NA & -904.596 & NA \tabularnewline
2 & 28549 & NA & NA & -1263.39 & NA \tabularnewline
3 & 33348 & NA & NA & 1679.41 & NA \tabularnewline
4 & 29017 & NA & NA & -150.138 & NA \tabularnewline
5 & 30924 & NA & NA & 404.674 & NA \tabularnewline
6 & 30435 & NA & NA & 472.737 & NA \tabularnewline
7 & 29431 & 30508.2 & 30487.3 & 20.8932 & -1077.23 \tabularnewline
8 & 30290 & 29631.8 & 30712 & -1080.13 & 658.169 \tabularnewline
9 & 31286 & 30938.2 & 30884.3 & 53.8828 & 347.826 \tabularnewline
10 & 30622 & 32415.1 & 31004.9 & 1410.22 & -1793.09 \tabularnewline
11 & 31742 & 31591 & 31197 & 394.091 & 150.951 \tabularnewline
12 & 30391 & 30336 & 31373.7 & -1037.66 & 54.9505 \tabularnewline
13 & 30740 & 30663.5 & 31568.1 & -904.596 & 76.4714 \tabularnewline
14 & 32086 & 30517.8 & 31781.2 & -1263.39 & 1568.18 \tabularnewline
15 & 33947 & 33564.8 & 31885.4 & 1679.41 & 382.169 \tabularnewline
16 & 31312 & 31918.4 & 32068.5 & -150.138 & -606.404 \tabularnewline
17 & 33239 & 32741.8 & 32337.1 & 404.674 & 497.201 \tabularnewline
18 & 32362 & 32913.7 & 32441 & 472.737 & -551.695 \tabularnewline
19 & 32170 & 32562.7 & 32541.8 & 20.8932 & -392.727 \tabularnewline
20 & 32665 & 31519.5 & 32599.7 & -1080.13 & 1145.46 \tabularnewline
21 & 31412 & 32589.6 & 32535.7 & 53.8828 & -1177.59 \tabularnewline
22 & 34891 & 33926.6 & 32516.4 & 1410.22 & 964.409 \tabularnewline
23 & 33919 & 32921 & 32526.9 & 394.091 & 997.992 \tabularnewline
24 & 30706 & 31478.4 & 32516 & -1037.66 & -772.383 \tabularnewline
25 & 32846 & 31607.2 & 32511.8 & -904.596 & 1238.76 \tabularnewline
26 & 31368 & 31151.9 & 32415.2 & -1263.39 & 216.138 \tabularnewline
27 & 33130 & 34016.7 & 32337.2 & 1679.41 & -886.664 \tabularnewline
28 & 31665 & 32164.9 & 32315.1 & -150.138 & -499.945 \tabularnewline
29 & 33139 & 32606.2 & 32201.5 & 404.674 & 532.784 \tabularnewline
30 & 32201 & 32636.4 & 32163.7 & 472.737 & -435.404 \tabularnewline
31 & 32230 & 32177.6 & 32156.7 & 20.8932 & 52.3568 \tabularnewline
32 & 30287 & 30991.1 & 32071.2 & -1080.13 & -704.122 \tabularnewline
33 & 31918 & 32066.2 & 32012.3 & 53.8828 & -148.174 \tabularnewline
34 & 33853 & 33424.4 & 32014.2 & 1410.22 & 428.576 \tabularnewline
35 & 32232 & 32379.7 & 31985.6 & 394.091 & -147.716 \tabularnewline
36 & 31484 & 30894.3 & 31932 & -1037.66 & 589.701 \tabularnewline
37 & 31902 & 31060.5 & 31965.1 & -904.596 & 841.513 \tabularnewline
38 & 30260 & 30712 & 31975.4 & -1263.39 & -452.029 \tabularnewline
39 & 32823 & 33656.4 & 31977 & 1679.41 & -833.372 \tabularnewline
40 & 32018 & 31852.8 & 32002.9 & -150.138 & 165.221 \tabularnewline
41 & 32100 & 32356.9 & 31952.3 & 404.674 & -256.924 \tabularnewline
42 & 31952 & 32361.9 & 31889.2 & 472.737 & -409.904 \tabularnewline
43 & 33274 & 31763 & 31742.1 & 20.8932 & 1511.02 \tabularnewline
44 & 29491 & 30497.1 & 31577.2 & -1080.13 & -1006.08 \tabularnewline
45 & 32751 & 31679.6 & 31625.8 & 53.8828 & 1071.37 \tabularnewline
46 & 33643 & 33149.5 & 31739.2 & 1410.22 & 493.534 \tabularnewline
47 & 31226 & 32133.8 & 31739.7 & 394.091 & -907.799 \tabularnewline
48 & 30976 & 30754.8 & 31792.5 & -1037.66 & 221.159 \tabularnewline
49 & 28880 & 30943.3 & 31847.9 & -904.596 & -2063.32 \tabularnewline
50 & 29325 & 30563.9 & 31827.2 & -1263.39 & -1238.86 \tabularnewline
51 & 34923 & 33491.7 & 31812.3 & 1679.41 & 1431.29 \tabularnewline
52 & 32642 & 31607.4 & 31757.6 & -150.138 & 1034.55 \tabularnewline
53 & 31487 & 32166.6 & 31762 & 404.674 & -679.633 \tabularnewline
54 & 33832 & 32341.6 & 31868.8 & 472.737 & 1490.43 \tabularnewline
55 & 32724 & NA & NA & 20.8932 & NA \tabularnewline
56 & 29545 & NA & NA & -1080.13 & NA \tabularnewline
57 & 32338 & NA & NA & 53.8828 & NA \tabularnewline
58 & 32743 & NA & NA & 1410.22 & NA \tabularnewline
59 & 32231 & NA & NA & 394.091 & NA \tabularnewline
60 & 32536 & NA & NA & -1037.66 & NA \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=&T=1

[TABLE]
[ROW][C]Classical Decomposition by Moving Averages[/C][/ROW]
[ROW][C]t[/C][C]Observations[/C][C]Fit[/C][C]Trend[/C][C]Seasonal[/C][C]Random[/C][/ROW]
[ROW][C]1[/C][C]28886[/C][C]NA[/C][C]NA[/C][C]-904.596[/C][C]NA[/C][/ROW]
[ROW][C]2[/C][C]28549[/C][C]NA[/C][C]NA[/C][C]-1263.39[/C][C]NA[/C][/ROW]
[ROW][C]3[/C][C]33348[/C][C]NA[/C][C]NA[/C][C]1679.41[/C][C]NA[/C][/ROW]
[ROW][C]4[/C][C]29017[/C][C]NA[/C][C]NA[/C][C]-150.138[/C][C]NA[/C][/ROW]
[ROW][C]5[/C][C]30924[/C][C]NA[/C][C]NA[/C][C]404.674[/C][C]NA[/C][/ROW]
[ROW][C]6[/C][C]30435[/C][C]NA[/C][C]NA[/C][C]472.737[/C][C]NA[/C][/ROW]
[ROW][C]7[/C][C]29431[/C][C]30508.2[/C][C]30487.3[/C][C]20.8932[/C][C]-1077.23[/C][/ROW]
[ROW][C]8[/C][C]30290[/C][C]29631.8[/C][C]30712[/C][C]-1080.13[/C][C]658.169[/C][/ROW]
[ROW][C]9[/C][C]31286[/C][C]30938.2[/C][C]30884.3[/C][C]53.8828[/C][C]347.826[/C][/ROW]
[ROW][C]10[/C][C]30622[/C][C]32415.1[/C][C]31004.9[/C][C]1410.22[/C][C]-1793.09[/C][/ROW]
[ROW][C]11[/C][C]31742[/C][C]31591[/C][C]31197[/C][C]394.091[/C][C]150.951[/C][/ROW]
[ROW][C]12[/C][C]30391[/C][C]30336[/C][C]31373.7[/C][C]-1037.66[/C][C]54.9505[/C][/ROW]
[ROW][C]13[/C][C]30740[/C][C]30663.5[/C][C]31568.1[/C][C]-904.596[/C][C]76.4714[/C][/ROW]
[ROW][C]14[/C][C]32086[/C][C]30517.8[/C][C]31781.2[/C][C]-1263.39[/C][C]1568.18[/C][/ROW]
[ROW][C]15[/C][C]33947[/C][C]33564.8[/C][C]31885.4[/C][C]1679.41[/C][C]382.169[/C][/ROW]
[ROW][C]16[/C][C]31312[/C][C]31918.4[/C][C]32068.5[/C][C]-150.138[/C][C]-606.404[/C][/ROW]
[ROW][C]17[/C][C]33239[/C][C]32741.8[/C][C]32337.1[/C][C]404.674[/C][C]497.201[/C][/ROW]
[ROW][C]18[/C][C]32362[/C][C]32913.7[/C][C]32441[/C][C]472.737[/C][C]-551.695[/C][/ROW]
[ROW][C]19[/C][C]32170[/C][C]32562.7[/C][C]32541.8[/C][C]20.8932[/C][C]-392.727[/C][/ROW]
[ROW][C]20[/C][C]32665[/C][C]31519.5[/C][C]32599.7[/C][C]-1080.13[/C][C]1145.46[/C][/ROW]
[ROW][C]21[/C][C]31412[/C][C]32589.6[/C][C]32535.7[/C][C]53.8828[/C][C]-1177.59[/C][/ROW]
[ROW][C]22[/C][C]34891[/C][C]33926.6[/C][C]32516.4[/C][C]1410.22[/C][C]964.409[/C][/ROW]
[ROW][C]23[/C][C]33919[/C][C]32921[/C][C]32526.9[/C][C]394.091[/C][C]997.992[/C][/ROW]
[ROW][C]24[/C][C]30706[/C][C]31478.4[/C][C]32516[/C][C]-1037.66[/C][C]-772.383[/C][/ROW]
[ROW][C]25[/C][C]32846[/C][C]31607.2[/C][C]32511.8[/C][C]-904.596[/C][C]1238.76[/C][/ROW]
[ROW][C]26[/C][C]31368[/C][C]31151.9[/C][C]32415.2[/C][C]-1263.39[/C][C]216.138[/C][/ROW]
[ROW][C]27[/C][C]33130[/C][C]34016.7[/C][C]32337.2[/C][C]1679.41[/C][C]-886.664[/C][/ROW]
[ROW][C]28[/C][C]31665[/C][C]32164.9[/C][C]32315.1[/C][C]-150.138[/C][C]-499.945[/C][/ROW]
[ROW][C]29[/C][C]33139[/C][C]32606.2[/C][C]32201.5[/C][C]404.674[/C][C]532.784[/C][/ROW]
[ROW][C]30[/C][C]32201[/C][C]32636.4[/C][C]32163.7[/C][C]472.737[/C][C]-435.404[/C][/ROW]
[ROW][C]31[/C][C]32230[/C][C]32177.6[/C][C]32156.7[/C][C]20.8932[/C][C]52.3568[/C][/ROW]
[ROW][C]32[/C][C]30287[/C][C]30991.1[/C][C]32071.2[/C][C]-1080.13[/C][C]-704.122[/C][/ROW]
[ROW][C]33[/C][C]31918[/C][C]32066.2[/C][C]32012.3[/C][C]53.8828[/C][C]-148.174[/C][/ROW]
[ROW][C]34[/C][C]33853[/C][C]33424.4[/C][C]32014.2[/C][C]1410.22[/C][C]428.576[/C][/ROW]
[ROW][C]35[/C][C]32232[/C][C]32379.7[/C][C]31985.6[/C][C]394.091[/C][C]-147.716[/C][/ROW]
[ROW][C]36[/C][C]31484[/C][C]30894.3[/C][C]31932[/C][C]-1037.66[/C][C]589.701[/C][/ROW]
[ROW][C]37[/C][C]31902[/C][C]31060.5[/C][C]31965.1[/C][C]-904.596[/C][C]841.513[/C][/ROW]
[ROW][C]38[/C][C]30260[/C][C]30712[/C][C]31975.4[/C][C]-1263.39[/C][C]-452.029[/C][/ROW]
[ROW][C]39[/C][C]32823[/C][C]33656.4[/C][C]31977[/C][C]1679.41[/C][C]-833.372[/C][/ROW]
[ROW][C]40[/C][C]32018[/C][C]31852.8[/C][C]32002.9[/C][C]-150.138[/C][C]165.221[/C][/ROW]
[ROW][C]41[/C][C]32100[/C][C]32356.9[/C][C]31952.3[/C][C]404.674[/C][C]-256.924[/C][/ROW]
[ROW][C]42[/C][C]31952[/C][C]32361.9[/C][C]31889.2[/C][C]472.737[/C][C]-409.904[/C][/ROW]
[ROW][C]43[/C][C]33274[/C][C]31763[/C][C]31742.1[/C][C]20.8932[/C][C]1511.02[/C][/ROW]
[ROW][C]44[/C][C]29491[/C][C]30497.1[/C][C]31577.2[/C][C]-1080.13[/C][C]-1006.08[/C][/ROW]
[ROW][C]45[/C][C]32751[/C][C]31679.6[/C][C]31625.8[/C][C]53.8828[/C][C]1071.37[/C][/ROW]
[ROW][C]46[/C][C]33643[/C][C]33149.5[/C][C]31739.2[/C][C]1410.22[/C][C]493.534[/C][/ROW]
[ROW][C]47[/C][C]31226[/C][C]32133.8[/C][C]31739.7[/C][C]394.091[/C][C]-907.799[/C][/ROW]
[ROW][C]48[/C][C]30976[/C][C]30754.8[/C][C]31792.5[/C][C]-1037.66[/C][C]221.159[/C][/ROW]
[ROW][C]49[/C][C]28880[/C][C]30943.3[/C][C]31847.9[/C][C]-904.596[/C][C]-2063.32[/C][/ROW]
[ROW][C]50[/C][C]29325[/C][C]30563.9[/C][C]31827.2[/C][C]-1263.39[/C][C]-1238.86[/C][/ROW]
[ROW][C]51[/C][C]34923[/C][C]33491.7[/C][C]31812.3[/C][C]1679.41[/C][C]1431.29[/C][/ROW]
[ROW][C]52[/C][C]32642[/C][C]31607.4[/C][C]31757.6[/C][C]-150.138[/C][C]1034.55[/C][/ROW]
[ROW][C]53[/C][C]31487[/C][C]32166.6[/C][C]31762[/C][C]404.674[/C][C]-679.633[/C][/ROW]
[ROW][C]54[/C][C]33832[/C][C]32341.6[/C][C]31868.8[/C][C]472.737[/C][C]1490.43[/C][/ROW]
[ROW][C]55[/C][C]32724[/C][C]NA[/C][C]NA[/C][C]20.8932[/C][C]NA[/C][/ROW]
[ROW][C]56[/C][C]29545[/C][C]NA[/C][C]NA[/C][C]-1080.13[/C][C]NA[/C][/ROW]
[ROW][C]57[/C][C]32338[/C][C]NA[/C][C]NA[/C][C]53.8828[/C][C]NA[/C][/ROW]
[ROW][C]58[/C][C]32743[/C][C]NA[/C][C]NA[/C][C]1410.22[/C][C]NA[/C][/ROW]
[ROW][C]59[/C][C]32231[/C][C]NA[/C][C]NA[/C][C]394.091[/C][C]NA[/C][/ROW]
[ROW][C]60[/C][C]32536[/C][C]NA[/C][C]NA[/C][C]-1037.66[/C][C]NA[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=&T=1

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=&T=1

As an alternative you can also use a QR Code:  

The GUIDs for individual cells are displayed in the table below:

Classical Decomposition by Moving Averages
tObservationsFitTrendSeasonalRandom
128886NANA-904.596NA
228549NANA-1263.39NA
333348NANA1679.41NA
429017NANA-150.138NA
530924NANA404.674NA
630435NANA472.737NA
72943130508.230487.320.8932-1077.23
83029029631.830712-1080.13658.169
93128630938.230884.353.8828347.826
103062232415.131004.91410.22-1793.09
11317423159131197394.091150.951
12303913033631373.7-1037.6654.9505
133074030663.531568.1-904.59676.4714
143208630517.831781.2-1263.391568.18
153394733564.831885.41679.41382.169
163131231918.432068.5-150.138-606.404
173323932741.832337.1404.674497.201
183236232913.732441472.737-551.695
193217032562.732541.820.8932-392.727
203266531519.532599.7-1080.131145.46
213141232589.632535.753.8828-1177.59
223489133926.632516.41410.22964.409
23339193292132526.9394.091997.992
243070631478.432516-1037.66-772.383
253284631607.232511.8-904.5961238.76
263136831151.932415.2-1263.39216.138
273313034016.732337.21679.41-886.664
283166532164.932315.1-150.138-499.945
293313932606.232201.5404.674532.784
303220132636.432163.7472.737-435.404
313223032177.632156.720.893252.3568
323028730991.132071.2-1080.13-704.122
333191832066.232012.353.8828-148.174
343385333424.432014.21410.22428.576
353223232379.731985.6394.091-147.716
363148430894.331932-1037.66589.701
373190231060.531965.1-904.596841.513
38302603071231975.4-1263.39-452.029
393282333656.4319771679.41-833.372
403201831852.832002.9-150.138165.221
413210032356.931952.3404.674-256.924
423195232361.931889.2472.737-409.904
43332743176331742.120.89321511.02
442949130497.131577.2-1080.13-1006.08
453275131679.631625.853.88281071.37
463364333149.531739.21410.22493.534
473122632133.831739.7394.091-907.799
483097630754.831792.5-1037.66221.159
492888030943.331847.9-904.596-2063.32
502932530563.931827.2-1263.39-1238.86
513492333491.731812.31679.411431.29
523264231607.431757.6-150.1381034.55
533148732166.631762404.674-679.633
543383232341.631868.8472.7371490.43
5532724NANA20.8932NA
5629545NANA-1080.13NA
5732338NANA53.8828NA
5832743NANA1410.22NA
5932231NANA394.091NA
6032536NANA-1037.66NA



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])
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')