Free Statistics

of Irreproducible Research!

Author's title

Author*Unverified author*
R Software Modulerwasp_decompose.wasp
Title produced by softwareClassical Decomposition
Date of computationSun, 27 Nov 2016 12:38:34 +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/27/t1480250444elg3o330vd4zbbo.htm/, Retrieved Sun, 19 May 2024 01:21:05 +0200
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL https://freestatistics.org/blog/index.php?pk=, Retrieved Sun, 19 May 2024 01:21:05 +0200
QR Codes:

Original text written by user:
IsPrivate?No (this computation is public)
User-defined keywords
Estimated Impact0
Dataseries X:
272 567
266 674
301 601
322 421
313 776
300 156
315 745
299 214
295 184
340 003
332 748
316 337
293 572
308 713
354 188
334 540
313 285
337 881
356 955
323 661
296 034
377 623
342 590
300 905
309 470
271 492
307 759
326 106
335 576
310 485
335 173
298 344
288 269
319 410
327 692
315 401
277 720
260 573
318 025
300 264
317 640
303 273
315 089
275 840
292 823
339 759
328 032
344 675
260 952
275 466
331 940
347 644
338 063
384 283
398 482
347 062
350 731
368 799
387 710
362 988





Summary of computational transaction
Raw Inputview raw input (R code)
Raw Outputview raw output of R engine
Computing time2 seconds
R Server'Sir Ronald Aylmer Fisher' @ fisher.wessa.net
R Framework error message
Warning: there are blank lines in the 'Data' field.
Please, use NA for missing data - blank lines are simply
 deleted and are NOT treated as missing values.

\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 & 'Sir Ronald Aylmer Fisher' @ fisher.wessa.net \tabularnewline
R Framework error message & 
Warning: there are blank lines in the 'Data' field.
Please, use NA for missing data - blank lines are simply
 deleted and are NOT treated as missing values.
\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]'Sir Ronald Aylmer Fisher' @ fisher.wessa.net[/C][/ROW]
[ROW][C]R Framework error message[/C][C]
Warning: there are blank lines in the 'Data' field.
Please, use NA for missing data - blank lines are simply
 deleted and are NOT treated as missing values.
[/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'Sir Ronald Aylmer Fisher' @ fisher.wessa.net
R Framework error message
Warning: there are blank lines in the 'Data' field.
Please, use NA for missing data - blank lines are simply
 deleted and are NOT treated as missing values.







Classical Decomposition by Moving Averages
tObservationsFitTrendSeasonalRandom
1272567NANA0.900997NA
2266674NANA0.876622NA
3301601NANA1.02746NA
4322421NANA1.02118NA
5313776NANA1.01746NA
6300156NANA1.03452NA
73157453249133072441.057510.971784
82992142965073098710.9568721.00913
92951842939813138140.93681.00409
103400033472423165101.09710.979152
113327483359083169941.059670.990593
123163373229453185461.013810.979537
132935722899723218350.9009971.01241
143087132845253245700.8766221.08501
153541883345653256241.027461.05865
163345403341603272271.021181.00114
173132853349543292051.017460.935309
183378813403283289721.034520.992809
193569553479113289911.057511.026
203236613139533281030.9568721.03092
212960343041023246170.93680.973471
223776233536303223321.09711.06785
233425903421753229091.059671.00121
243009053271533226961.013810.919768
253094702889023206470.9009971.07119
262714922793663186850.8766220.971815
273077593260183173061.027460.943993
283261063212213145571.021181.01521
293355763169513115111.017461.05876
303104853222473114941.034520.9635
313351733286473107751.057511.01986
322983442956713089970.9568721.00904
332882692894433089700.93680.995943
343194103382593083211.09710.944277
353276923247843064971.059671.00895
363154013096683054491.013811.01851
372777202741843043120.9009971.0129
382605732652113025370.8766220.982513
393180253100763017891.027461.02564
403002643092423028271.021180.970966
413176403089923036891.017461.02799
423032733154493049231.034520.961401
433150893230093054441.057510.97548
442758402921963053660.9568720.944023
452928232871913065660.93681.01961
463397593391353091201.09711.00184
473280323305583119451.059670.992359
483446753205393161721.013811.0753
492609522910423230220.9009970.896613
502754662888153294640.8766220.953779
513319403440383348451.027460.964834
523476443456383384671.021181.0058
533380633481393421641.017460.971057
543842833573373454141.034521.07541
55398482NANA1.05751NA
56347062NANA0.956872NA
57350731NANA0.9368NA
58368799NANA1.0971NA
59387710NANA1.05967NA
60362988NANA1.01381NA

\begin{tabular}{lllllllll}
\hline
Classical Decomposition by Moving Averages \tabularnewline
t & Observations & Fit & Trend & Seasonal & Random \tabularnewline
1 & 272567 & NA & NA & 0.900997 & NA \tabularnewline
2 & 266674 & NA & NA & 0.876622 & NA \tabularnewline
3 & 301601 & NA & NA & 1.02746 & NA \tabularnewline
4 & 322421 & NA & NA & 1.02118 & NA \tabularnewline
5 & 313776 & NA & NA & 1.01746 & NA \tabularnewline
6 & 300156 & NA & NA & 1.03452 & NA \tabularnewline
7 & 315745 & 324913 & 307244 & 1.05751 & 0.971784 \tabularnewline
8 & 299214 & 296507 & 309871 & 0.956872 & 1.00913 \tabularnewline
9 & 295184 & 293981 & 313814 & 0.9368 & 1.00409 \tabularnewline
10 & 340003 & 347242 & 316510 & 1.0971 & 0.979152 \tabularnewline
11 & 332748 & 335908 & 316994 & 1.05967 & 0.990593 \tabularnewline
12 & 316337 & 322945 & 318546 & 1.01381 & 0.979537 \tabularnewline
13 & 293572 & 289972 & 321835 & 0.900997 & 1.01241 \tabularnewline
14 & 308713 & 284525 & 324570 & 0.876622 & 1.08501 \tabularnewline
15 & 354188 & 334565 & 325624 & 1.02746 & 1.05865 \tabularnewline
16 & 334540 & 334160 & 327227 & 1.02118 & 1.00114 \tabularnewline
17 & 313285 & 334954 & 329205 & 1.01746 & 0.935309 \tabularnewline
18 & 337881 & 340328 & 328972 & 1.03452 & 0.992809 \tabularnewline
19 & 356955 & 347911 & 328991 & 1.05751 & 1.026 \tabularnewline
20 & 323661 & 313953 & 328103 & 0.956872 & 1.03092 \tabularnewline
21 & 296034 & 304102 & 324617 & 0.9368 & 0.973471 \tabularnewline
22 & 377623 & 353630 & 322332 & 1.0971 & 1.06785 \tabularnewline
23 & 342590 & 342175 & 322909 & 1.05967 & 1.00121 \tabularnewline
24 & 300905 & 327153 & 322696 & 1.01381 & 0.919768 \tabularnewline
25 & 309470 & 288902 & 320647 & 0.900997 & 1.07119 \tabularnewline
26 & 271492 & 279366 & 318685 & 0.876622 & 0.971815 \tabularnewline
27 & 307759 & 326018 & 317306 & 1.02746 & 0.943993 \tabularnewline
28 & 326106 & 321221 & 314557 & 1.02118 & 1.01521 \tabularnewline
29 & 335576 & 316951 & 311511 & 1.01746 & 1.05876 \tabularnewline
30 & 310485 & 322247 & 311494 & 1.03452 & 0.9635 \tabularnewline
31 & 335173 & 328647 & 310775 & 1.05751 & 1.01986 \tabularnewline
32 & 298344 & 295671 & 308997 & 0.956872 & 1.00904 \tabularnewline
33 & 288269 & 289443 & 308970 & 0.9368 & 0.995943 \tabularnewline
34 & 319410 & 338259 & 308321 & 1.0971 & 0.944277 \tabularnewline
35 & 327692 & 324784 & 306497 & 1.05967 & 1.00895 \tabularnewline
36 & 315401 & 309668 & 305449 & 1.01381 & 1.01851 \tabularnewline
37 & 277720 & 274184 & 304312 & 0.900997 & 1.0129 \tabularnewline
38 & 260573 & 265211 & 302537 & 0.876622 & 0.982513 \tabularnewline
39 & 318025 & 310076 & 301789 & 1.02746 & 1.02564 \tabularnewline
40 & 300264 & 309242 & 302827 & 1.02118 & 0.970966 \tabularnewline
41 & 317640 & 308992 & 303689 & 1.01746 & 1.02799 \tabularnewline
42 & 303273 & 315449 & 304923 & 1.03452 & 0.961401 \tabularnewline
43 & 315089 & 323009 & 305444 & 1.05751 & 0.97548 \tabularnewline
44 & 275840 & 292196 & 305366 & 0.956872 & 0.944023 \tabularnewline
45 & 292823 & 287191 & 306566 & 0.9368 & 1.01961 \tabularnewline
46 & 339759 & 339135 & 309120 & 1.0971 & 1.00184 \tabularnewline
47 & 328032 & 330558 & 311945 & 1.05967 & 0.992359 \tabularnewline
48 & 344675 & 320539 & 316172 & 1.01381 & 1.0753 \tabularnewline
49 & 260952 & 291042 & 323022 & 0.900997 & 0.896613 \tabularnewline
50 & 275466 & 288815 & 329464 & 0.876622 & 0.953779 \tabularnewline
51 & 331940 & 344038 & 334845 & 1.02746 & 0.964834 \tabularnewline
52 & 347644 & 345638 & 338467 & 1.02118 & 1.0058 \tabularnewline
53 & 338063 & 348139 & 342164 & 1.01746 & 0.971057 \tabularnewline
54 & 384283 & 357337 & 345414 & 1.03452 & 1.07541 \tabularnewline
55 & 398482 & NA & NA & 1.05751 & NA \tabularnewline
56 & 347062 & NA & NA & 0.956872 & NA \tabularnewline
57 & 350731 & NA & NA & 0.9368 & NA \tabularnewline
58 & 368799 & NA & NA & 1.0971 & NA \tabularnewline
59 & 387710 & NA & NA & 1.05967 & NA \tabularnewline
60 & 362988 & NA & NA & 1.01381 & 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]272567[/C][C]NA[/C][C]NA[/C][C]0.900997[/C][C]NA[/C][/ROW]
[ROW][C]2[/C][C]266674[/C][C]NA[/C][C]NA[/C][C]0.876622[/C][C]NA[/C][/ROW]
[ROW][C]3[/C][C]301601[/C][C]NA[/C][C]NA[/C][C]1.02746[/C][C]NA[/C][/ROW]
[ROW][C]4[/C][C]322421[/C][C]NA[/C][C]NA[/C][C]1.02118[/C][C]NA[/C][/ROW]
[ROW][C]5[/C][C]313776[/C][C]NA[/C][C]NA[/C][C]1.01746[/C][C]NA[/C][/ROW]
[ROW][C]6[/C][C]300156[/C][C]NA[/C][C]NA[/C][C]1.03452[/C][C]NA[/C][/ROW]
[ROW][C]7[/C][C]315745[/C][C]324913[/C][C]307244[/C][C]1.05751[/C][C]0.971784[/C][/ROW]
[ROW][C]8[/C][C]299214[/C][C]296507[/C][C]309871[/C][C]0.956872[/C][C]1.00913[/C][/ROW]
[ROW][C]9[/C][C]295184[/C][C]293981[/C][C]313814[/C][C]0.9368[/C][C]1.00409[/C][/ROW]
[ROW][C]10[/C][C]340003[/C][C]347242[/C][C]316510[/C][C]1.0971[/C][C]0.979152[/C][/ROW]
[ROW][C]11[/C][C]332748[/C][C]335908[/C][C]316994[/C][C]1.05967[/C][C]0.990593[/C][/ROW]
[ROW][C]12[/C][C]316337[/C][C]322945[/C][C]318546[/C][C]1.01381[/C][C]0.979537[/C][/ROW]
[ROW][C]13[/C][C]293572[/C][C]289972[/C][C]321835[/C][C]0.900997[/C][C]1.01241[/C][/ROW]
[ROW][C]14[/C][C]308713[/C][C]284525[/C][C]324570[/C][C]0.876622[/C][C]1.08501[/C][/ROW]
[ROW][C]15[/C][C]354188[/C][C]334565[/C][C]325624[/C][C]1.02746[/C][C]1.05865[/C][/ROW]
[ROW][C]16[/C][C]334540[/C][C]334160[/C][C]327227[/C][C]1.02118[/C][C]1.00114[/C][/ROW]
[ROW][C]17[/C][C]313285[/C][C]334954[/C][C]329205[/C][C]1.01746[/C][C]0.935309[/C][/ROW]
[ROW][C]18[/C][C]337881[/C][C]340328[/C][C]328972[/C][C]1.03452[/C][C]0.992809[/C][/ROW]
[ROW][C]19[/C][C]356955[/C][C]347911[/C][C]328991[/C][C]1.05751[/C][C]1.026[/C][/ROW]
[ROW][C]20[/C][C]323661[/C][C]313953[/C][C]328103[/C][C]0.956872[/C][C]1.03092[/C][/ROW]
[ROW][C]21[/C][C]296034[/C][C]304102[/C][C]324617[/C][C]0.9368[/C][C]0.973471[/C][/ROW]
[ROW][C]22[/C][C]377623[/C][C]353630[/C][C]322332[/C][C]1.0971[/C][C]1.06785[/C][/ROW]
[ROW][C]23[/C][C]342590[/C][C]342175[/C][C]322909[/C][C]1.05967[/C][C]1.00121[/C][/ROW]
[ROW][C]24[/C][C]300905[/C][C]327153[/C][C]322696[/C][C]1.01381[/C][C]0.919768[/C][/ROW]
[ROW][C]25[/C][C]309470[/C][C]288902[/C][C]320647[/C][C]0.900997[/C][C]1.07119[/C][/ROW]
[ROW][C]26[/C][C]271492[/C][C]279366[/C][C]318685[/C][C]0.876622[/C][C]0.971815[/C][/ROW]
[ROW][C]27[/C][C]307759[/C][C]326018[/C][C]317306[/C][C]1.02746[/C][C]0.943993[/C][/ROW]
[ROW][C]28[/C][C]326106[/C][C]321221[/C][C]314557[/C][C]1.02118[/C][C]1.01521[/C][/ROW]
[ROW][C]29[/C][C]335576[/C][C]316951[/C][C]311511[/C][C]1.01746[/C][C]1.05876[/C][/ROW]
[ROW][C]30[/C][C]310485[/C][C]322247[/C][C]311494[/C][C]1.03452[/C][C]0.9635[/C][/ROW]
[ROW][C]31[/C][C]335173[/C][C]328647[/C][C]310775[/C][C]1.05751[/C][C]1.01986[/C][/ROW]
[ROW][C]32[/C][C]298344[/C][C]295671[/C][C]308997[/C][C]0.956872[/C][C]1.00904[/C][/ROW]
[ROW][C]33[/C][C]288269[/C][C]289443[/C][C]308970[/C][C]0.9368[/C][C]0.995943[/C][/ROW]
[ROW][C]34[/C][C]319410[/C][C]338259[/C][C]308321[/C][C]1.0971[/C][C]0.944277[/C][/ROW]
[ROW][C]35[/C][C]327692[/C][C]324784[/C][C]306497[/C][C]1.05967[/C][C]1.00895[/C][/ROW]
[ROW][C]36[/C][C]315401[/C][C]309668[/C][C]305449[/C][C]1.01381[/C][C]1.01851[/C][/ROW]
[ROW][C]37[/C][C]277720[/C][C]274184[/C][C]304312[/C][C]0.900997[/C][C]1.0129[/C][/ROW]
[ROW][C]38[/C][C]260573[/C][C]265211[/C][C]302537[/C][C]0.876622[/C][C]0.982513[/C][/ROW]
[ROW][C]39[/C][C]318025[/C][C]310076[/C][C]301789[/C][C]1.02746[/C][C]1.02564[/C][/ROW]
[ROW][C]40[/C][C]300264[/C][C]309242[/C][C]302827[/C][C]1.02118[/C][C]0.970966[/C][/ROW]
[ROW][C]41[/C][C]317640[/C][C]308992[/C][C]303689[/C][C]1.01746[/C][C]1.02799[/C][/ROW]
[ROW][C]42[/C][C]303273[/C][C]315449[/C][C]304923[/C][C]1.03452[/C][C]0.961401[/C][/ROW]
[ROW][C]43[/C][C]315089[/C][C]323009[/C][C]305444[/C][C]1.05751[/C][C]0.97548[/C][/ROW]
[ROW][C]44[/C][C]275840[/C][C]292196[/C][C]305366[/C][C]0.956872[/C][C]0.944023[/C][/ROW]
[ROW][C]45[/C][C]292823[/C][C]287191[/C][C]306566[/C][C]0.9368[/C][C]1.01961[/C][/ROW]
[ROW][C]46[/C][C]339759[/C][C]339135[/C][C]309120[/C][C]1.0971[/C][C]1.00184[/C][/ROW]
[ROW][C]47[/C][C]328032[/C][C]330558[/C][C]311945[/C][C]1.05967[/C][C]0.992359[/C][/ROW]
[ROW][C]48[/C][C]344675[/C][C]320539[/C][C]316172[/C][C]1.01381[/C][C]1.0753[/C][/ROW]
[ROW][C]49[/C][C]260952[/C][C]291042[/C][C]323022[/C][C]0.900997[/C][C]0.896613[/C][/ROW]
[ROW][C]50[/C][C]275466[/C][C]288815[/C][C]329464[/C][C]0.876622[/C][C]0.953779[/C][/ROW]
[ROW][C]51[/C][C]331940[/C][C]344038[/C][C]334845[/C][C]1.02746[/C][C]0.964834[/C][/ROW]
[ROW][C]52[/C][C]347644[/C][C]345638[/C][C]338467[/C][C]1.02118[/C][C]1.0058[/C][/ROW]
[ROW][C]53[/C][C]338063[/C][C]348139[/C][C]342164[/C][C]1.01746[/C][C]0.971057[/C][/ROW]
[ROW][C]54[/C][C]384283[/C][C]357337[/C][C]345414[/C][C]1.03452[/C][C]1.07541[/C][/ROW]
[ROW][C]55[/C][C]398482[/C][C]NA[/C][C]NA[/C][C]1.05751[/C][C]NA[/C][/ROW]
[ROW][C]56[/C][C]347062[/C][C]NA[/C][C]NA[/C][C]0.956872[/C][C]NA[/C][/ROW]
[ROW][C]57[/C][C]350731[/C][C]NA[/C][C]NA[/C][C]0.9368[/C][C]NA[/C][/ROW]
[ROW][C]58[/C][C]368799[/C][C]NA[/C][C]NA[/C][C]1.0971[/C][C]NA[/C][/ROW]
[ROW][C]59[/C][C]387710[/C][C]NA[/C][C]NA[/C][C]1.05967[/C][C]NA[/C][/ROW]
[ROW][C]60[/C][C]362988[/C][C]NA[/C][C]NA[/C][C]1.01381[/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
1272567NANA0.900997NA
2266674NANA0.876622NA
3301601NANA1.02746NA
4322421NANA1.02118NA
5313776NANA1.01746NA
6300156NANA1.03452NA
73157453249133072441.057510.971784
82992142965073098710.9568721.00913
92951842939813138140.93681.00409
103400033472423165101.09710.979152
113327483359083169941.059670.990593
123163373229453185461.013810.979537
132935722899723218350.9009971.01241
143087132845253245700.8766221.08501
153541883345653256241.027461.05865
163345403341603272271.021181.00114
173132853349543292051.017460.935309
183378813403283289721.034520.992809
193569553479113289911.057511.026
203236613139533281030.9568721.03092
212960343041023246170.93680.973471
223776233536303223321.09711.06785
233425903421753229091.059671.00121
243009053271533226961.013810.919768
253094702889023206470.9009971.07119
262714922793663186850.8766220.971815
273077593260183173061.027460.943993
283261063212213145571.021181.01521
293355763169513115111.017461.05876
303104853222473114941.034520.9635
313351733286473107751.057511.01986
322983442956713089970.9568721.00904
332882692894433089700.93680.995943
343194103382593083211.09710.944277
353276923247843064971.059671.00895
363154013096683054491.013811.01851
372777202741843043120.9009971.0129
382605732652113025370.8766220.982513
393180253100763017891.027461.02564
403002643092423028271.021180.970966
413176403089923036891.017461.02799
423032733154493049231.034520.961401
433150893230093054441.057510.97548
442758402921963053660.9568720.944023
452928232871913065660.93681.01961
463397593391353091201.09711.00184
473280323305583119451.059670.992359
483446753205393161721.013811.0753
492609522910423230220.9009970.896613
502754662888153294640.8766220.953779
513319403440383348451.027460.964834
523476443456383384671.021181.0058
533380633481393421641.017460.971057
543842833573373454141.034521.07541
55398482NANA1.05751NA
56347062NANA0.956872NA
57350731NANA0.9368NA
58368799NANA1.0971NA
59387710NANA1.05967NA
60362988NANA1.01381NA



Parameters (Session):
par1 = multiplicative ; par2 = 12 ;
Parameters (R input):
par1 = multiplicative ; 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')