Free Statistics

of Irreproducible Research!

Author's title

Author*Unverified author*
R Software Modulerwasp_decompose.wasp
Title produced by softwareClassical Decomposition
Date of computationMon, 01 May 2017 14:01:08 +0100
Cite this page as followsStatistical Computations at FreeStatistics.org, Office for Research Development and Education, URL https://freestatistics.org/blog/index.php?v=date/2017/May/01/t1493643755eujjh3ujfbr8ldw.htm/, Retrieved Wed, 15 May 2024 21:21:55 +0200
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL https://freestatistics.org/blog/index.php?pk=, Retrieved Wed, 15 May 2024 21:21:55 +0200
QR Codes:

Original text written by user:
IsPrivate?No (this computation is public)
User-defined keywords
Estimated Impact0
Dataseries X:
97,91	
98,51	
98,54	
98,52	
98,66	
98,53	
98,71	
98,92	
98,96	
99,25	
99,32	
99,41	
99,36	
99,58	
99,77	
99,77	
100,03	
100,2	
100,24	
100,1	
100,03	
100,18	
100,29	
100,41	
100,6	
100,75	
100,79	
100,44	
100,29	
100,34	
100,46	
100,12	
100,06	
100,28	
100,28	
100,4	
100,61	
100,89	
100,73	
101,12	
101,16	
101,33	
101,37	
101,61	
101,85	
102,27	
102,28	
102,23	
102,42	
102,53	
103,47	
103,53	
103,77	
103,74	
103,93	
103,97	
103,68	
103,86	
103,97	
104,05	




Summary of computational transaction
Raw Inputview raw input (R code)
Raw Outputview raw output of R engine
Computing time3 seconds
R Server'Sir Maurice George Kendall' @ kendall.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 & 3 seconds \tabularnewline
R Server & 'Sir Maurice George Kendall' @ kendall.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]3 seconds[/C][/ROW]
[ROW][C]R Server[/C][C]'Sir Maurice George Kendall' @ kendall.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 time3 seconds
R Server'Sir Maurice George Kendall' @ kendall.wessa.net







Classical Decomposition by Moving Averages
tObservationsFitTrendSeasonalRandom
197.91NANA0.99938NA
298.51NANA1.00021NA
398.54NANA1.00167NA
498.52NANA1.00095NA
598.66NANA1.00096NA
698.53NANA1.00091NA
798.7198.821998.83040.9999130.998868
898.9298.831998.93540.9989531.00089
998.9698.872299.03120.9983941.00089
1099.2599.139699.13461.000051.00111
1199.3299.192299.24370.9994811.00129
1299.4199.28399.37040.999121.00128
1399.3699.44299.50370.999380.999175
1499.5899.638199.61671.000210.999417
1599.7799.877299.71041.001670.998926
1699.7799.888999.79381.000950.998809
17100.0399.968899.87291.000961.00061
18100.2100.04699.9551.000911.00154
19100.24100.04100.0480.9999131.002
20100.1100.044100.1490.9989531.00056
21100.03100.079100.240.9983940.99951
22100.18100.315100.311.000050.998649
23100.29100.297100.3490.9994810.999929
24100.41100.277100.3660.999121.00132
25100.6100.319100.3810.999381.00281
26100.75100.412100.3911.000211.00336
27100.79100.561100.3931.001671.00228
28100.44100.494100.3981.000950.999462
29100.29100.499100.4021.000960.997925
30100.34100.492100.4011.000910.998486
31100.46100.393100.4010.9999131.00067
32100.12100.302100.4080.9989530.998181
33100.06100.25100.4110.9983940.998109
34100.28100.442100.4371.000050.99839
35100.28100.449100.5010.9994810.998317
36100.4100.49100.5790.999120.999102
37100.61100.595100.6580.999381.00014
38100.89100.78100.7581.000211.0011
39100.73101.063100.8951.001670.996701
40101.12101.148101.0521.000950.999719
41101.16101.316101.2181.000960.998465
42101.33101.47101.3781.000910.998623
43101.37101.521101.530.9999130.998515
44101.61101.567101.6730.9989531.00042
45101.85101.692101.8560.9983941.00155
46102.27102.076102.071.000051.0019
47102.28102.227102.280.9994811.00052
48102.23102.399102.4890.999120.998354
49102.42102.632102.6960.999380.997933
50102.53102.923102.9011.000210.996182
51103.47103.248103.0751.001671.00215
52103.53103.316103.2181.000951.00207
53103.77103.454103.3551.000961.00306
54103.74103.595103.5011.000911.0014
55103.93NANA0.999913NA
56103.97NANA0.998953NA
57103.68NANA0.998394NA
58103.86NANA1.00005NA
59103.97NANA0.999481NA
60104.05NANA0.99912NA

\begin{tabular}{lllllllll}
\hline
Classical Decomposition by Moving Averages \tabularnewline
t & Observations & Fit & Trend & Seasonal & Random \tabularnewline
1 & 97.91 & NA & NA & 0.99938 & NA \tabularnewline
2 & 98.51 & NA & NA & 1.00021 & NA \tabularnewline
3 & 98.54 & NA & NA & 1.00167 & NA \tabularnewline
4 & 98.52 & NA & NA & 1.00095 & NA \tabularnewline
5 & 98.66 & NA & NA & 1.00096 & NA \tabularnewline
6 & 98.53 & NA & NA & 1.00091 & NA \tabularnewline
7 & 98.71 & 98.8219 & 98.8304 & 0.999913 & 0.998868 \tabularnewline
8 & 98.92 & 98.8319 & 98.9354 & 0.998953 & 1.00089 \tabularnewline
9 & 98.96 & 98.8722 & 99.0312 & 0.998394 & 1.00089 \tabularnewline
10 & 99.25 & 99.1396 & 99.1346 & 1.00005 & 1.00111 \tabularnewline
11 & 99.32 & 99.1922 & 99.2437 & 0.999481 & 1.00129 \tabularnewline
12 & 99.41 & 99.283 & 99.3704 & 0.99912 & 1.00128 \tabularnewline
13 & 99.36 & 99.442 & 99.5037 & 0.99938 & 0.999175 \tabularnewline
14 & 99.58 & 99.6381 & 99.6167 & 1.00021 & 0.999417 \tabularnewline
15 & 99.77 & 99.8772 & 99.7104 & 1.00167 & 0.998926 \tabularnewline
16 & 99.77 & 99.8889 & 99.7938 & 1.00095 & 0.998809 \tabularnewline
17 & 100.03 & 99.9688 & 99.8729 & 1.00096 & 1.00061 \tabularnewline
18 & 100.2 & 100.046 & 99.955 & 1.00091 & 1.00154 \tabularnewline
19 & 100.24 & 100.04 & 100.048 & 0.999913 & 1.002 \tabularnewline
20 & 100.1 & 100.044 & 100.149 & 0.998953 & 1.00056 \tabularnewline
21 & 100.03 & 100.079 & 100.24 & 0.998394 & 0.99951 \tabularnewline
22 & 100.18 & 100.315 & 100.31 & 1.00005 & 0.998649 \tabularnewline
23 & 100.29 & 100.297 & 100.349 & 0.999481 & 0.999929 \tabularnewline
24 & 100.41 & 100.277 & 100.366 & 0.99912 & 1.00132 \tabularnewline
25 & 100.6 & 100.319 & 100.381 & 0.99938 & 1.00281 \tabularnewline
26 & 100.75 & 100.412 & 100.391 & 1.00021 & 1.00336 \tabularnewline
27 & 100.79 & 100.561 & 100.393 & 1.00167 & 1.00228 \tabularnewline
28 & 100.44 & 100.494 & 100.398 & 1.00095 & 0.999462 \tabularnewline
29 & 100.29 & 100.499 & 100.402 & 1.00096 & 0.997925 \tabularnewline
30 & 100.34 & 100.492 & 100.401 & 1.00091 & 0.998486 \tabularnewline
31 & 100.46 & 100.393 & 100.401 & 0.999913 & 1.00067 \tabularnewline
32 & 100.12 & 100.302 & 100.408 & 0.998953 & 0.998181 \tabularnewline
33 & 100.06 & 100.25 & 100.411 & 0.998394 & 0.998109 \tabularnewline
34 & 100.28 & 100.442 & 100.437 & 1.00005 & 0.99839 \tabularnewline
35 & 100.28 & 100.449 & 100.501 & 0.999481 & 0.998317 \tabularnewline
36 & 100.4 & 100.49 & 100.579 & 0.99912 & 0.999102 \tabularnewline
37 & 100.61 & 100.595 & 100.658 & 0.99938 & 1.00014 \tabularnewline
38 & 100.89 & 100.78 & 100.758 & 1.00021 & 1.0011 \tabularnewline
39 & 100.73 & 101.063 & 100.895 & 1.00167 & 0.996701 \tabularnewline
40 & 101.12 & 101.148 & 101.052 & 1.00095 & 0.999719 \tabularnewline
41 & 101.16 & 101.316 & 101.218 & 1.00096 & 0.998465 \tabularnewline
42 & 101.33 & 101.47 & 101.378 & 1.00091 & 0.998623 \tabularnewline
43 & 101.37 & 101.521 & 101.53 & 0.999913 & 0.998515 \tabularnewline
44 & 101.61 & 101.567 & 101.673 & 0.998953 & 1.00042 \tabularnewline
45 & 101.85 & 101.692 & 101.856 & 0.998394 & 1.00155 \tabularnewline
46 & 102.27 & 102.076 & 102.07 & 1.00005 & 1.0019 \tabularnewline
47 & 102.28 & 102.227 & 102.28 & 0.999481 & 1.00052 \tabularnewline
48 & 102.23 & 102.399 & 102.489 & 0.99912 & 0.998354 \tabularnewline
49 & 102.42 & 102.632 & 102.696 & 0.99938 & 0.997933 \tabularnewline
50 & 102.53 & 102.923 & 102.901 & 1.00021 & 0.996182 \tabularnewline
51 & 103.47 & 103.248 & 103.075 & 1.00167 & 1.00215 \tabularnewline
52 & 103.53 & 103.316 & 103.218 & 1.00095 & 1.00207 \tabularnewline
53 & 103.77 & 103.454 & 103.355 & 1.00096 & 1.00306 \tabularnewline
54 & 103.74 & 103.595 & 103.501 & 1.00091 & 1.0014 \tabularnewline
55 & 103.93 & NA & NA & 0.999913 & NA \tabularnewline
56 & 103.97 & NA & NA & 0.998953 & NA \tabularnewline
57 & 103.68 & NA & NA & 0.998394 & NA \tabularnewline
58 & 103.86 & NA & NA & 1.00005 & NA \tabularnewline
59 & 103.97 & NA & NA & 0.999481 & NA \tabularnewline
60 & 104.05 & NA & NA & 0.99912 & 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]97.91[/C][C]NA[/C][C]NA[/C][C]0.99938[/C][C]NA[/C][/ROW]
[ROW][C]2[/C][C]98.51[/C][C]NA[/C][C]NA[/C][C]1.00021[/C][C]NA[/C][/ROW]
[ROW][C]3[/C][C]98.54[/C][C]NA[/C][C]NA[/C][C]1.00167[/C][C]NA[/C][/ROW]
[ROW][C]4[/C][C]98.52[/C][C]NA[/C][C]NA[/C][C]1.00095[/C][C]NA[/C][/ROW]
[ROW][C]5[/C][C]98.66[/C][C]NA[/C][C]NA[/C][C]1.00096[/C][C]NA[/C][/ROW]
[ROW][C]6[/C][C]98.53[/C][C]NA[/C][C]NA[/C][C]1.00091[/C][C]NA[/C][/ROW]
[ROW][C]7[/C][C]98.71[/C][C]98.8219[/C][C]98.8304[/C][C]0.999913[/C][C]0.998868[/C][/ROW]
[ROW][C]8[/C][C]98.92[/C][C]98.8319[/C][C]98.9354[/C][C]0.998953[/C][C]1.00089[/C][/ROW]
[ROW][C]9[/C][C]98.96[/C][C]98.8722[/C][C]99.0312[/C][C]0.998394[/C][C]1.00089[/C][/ROW]
[ROW][C]10[/C][C]99.25[/C][C]99.1396[/C][C]99.1346[/C][C]1.00005[/C][C]1.00111[/C][/ROW]
[ROW][C]11[/C][C]99.32[/C][C]99.1922[/C][C]99.2437[/C][C]0.999481[/C][C]1.00129[/C][/ROW]
[ROW][C]12[/C][C]99.41[/C][C]99.283[/C][C]99.3704[/C][C]0.99912[/C][C]1.00128[/C][/ROW]
[ROW][C]13[/C][C]99.36[/C][C]99.442[/C][C]99.5037[/C][C]0.99938[/C][C]0.999175[/C][/ROW]
[ROW][C]14[/C][C]99.58[/C][C]99.6381[/C][C]99.6167[/C][C]1.00021[/C][C]0.999417[/C][/ROW]
[ROW][C]15[/C][C]99.77[/C][C]99.8772[/C][C]99.7104[/C][C]1.00167[/C][C]0.998926[/C][/ROW]
[ROW][C]16[/C][C]99.77[/C][C]99.8889[/C][C]99.7938[/C][C]1.00095[/C][C]0.998809[/C][/ROW]
[ROW][C]17[/C][C]100.03[/C][C]99.9688[/C][C]99.8729[/C][C]1.00096[/C][C]1.00061[/C][/ROW]
[ROW][C]18[/C][C]100.2[/C][C]100.046[/C][C]99.955[/C][C]1.00091[/C][C]1.00154[/C][/ROW]
[ROW][C]19[/C][C]100.24[/C][C]100.04[/C][C]100.048[/C][C]0.999913[/C][C]1.002[/C][/ROW]
[ROW][C]20[/C][C]100.1[/C][C]100.044[/C][C]100.149[/C][C]0.998953[/C][C]1.00056[/C][/ROW]
[ROW][C]21[/C][C]100.03[/C][C]100.079[/C][C]100.24[/C][C]0.998394[/C][C]0.99951[/C][/ROW]
[ROW][C]22[/C][C]100.18[/C][C]100.315[/C][C]100.31[/C][C]1.00005[/C][C]0.998649[/C][/ROW]
[ROW][C]23[/C][C]100.29[/C][C]100.297[/C][C]100.349[/C][C]0.999481[/C][C]0.999929[/C][/ROW]
[ROW][C]24[/C][C]100.41[/C][C]100.277[/C][C]100.366[/C][C]0.99912[/C][C]1.00132[/C][/ROW]
[ROW][C]25[/C][C]100.6[/C][C]100.319[/C][C]100.381[/C][C]0.99938[/C][C]1.00281[/C][/ROW]
[ROW][C]26[/C][C]100.75[/C][C]100.412[/C][C]100.391[/C][C]1.00021[/C][C]1.00336[/C][/ROW]
[ROW][C]27[/C][C]100.79[/C][C]100.561[/C][C]100.393[/C][C]1.00167[/C][C]1.00228[/C][/ROW]
[ROW][C]28[/C][C]100.44[/C][C]100.494[/C][C]100.398[/C][C]1.00095[/C][C]0.999462[/C][/ROW]
[ROW][C]29[/C][C]100.29[/C][C]100.499[/C][C]100.402[/C][C]1.00096[/C][C]0.997925[/C][/ROW]
[ROW][C]30[/C][C]100.34[/C][C]100.492[/C][C]100.401[/C][C]1.00091[/C][C]0.998486[/C][/ROW]
[ROW][C]31[/C][C]100.46[/C][C]100.393[/C][C]100.401[/C][C]0.999913[/C][C]1.00067[/C][/ROW]
[ROW][C]32[/C][C]100.12[/C][C]100.302[/C][C]100.408[/C][C]0.998953[/C][C]0.998181[/C][/ROW]
[ROW][C]33[/C][C]100.06[/C][C]100.25[/C][C]100.411[/C][C]0.998394[/C][C]0.998109[/C][/ROW]
[ROW][C]34[/C][C]100.28[/C][C]100.442[/C][C]100.437[/C][C]1.00005[/C][C]0.99839[/C][/ROW]
[ROW][C]35[/C][C]100.28[/C][C]100.449[/C][C]100.501[/C][C]0.999481[/C][C]0.998317[/C][/ROW]
[ROW][C]36[/C][C]100.4[/C][C]100.49[/C][C]100.579[/C][C]0.99912[/C][C]0.999102[/C][/ROW]
[ROW][C]37[/C][C]100.61[/C][C]100.595[/C][C]100.658[/C][C]0.99938[/C][C]1.00014[/C][/ROW]
[ROW][C]38[/C][C]100.89[/C][C]100.78[/C][C]100.758[/C][C]1.00021[/C][C]1.0011[/C][/ROW]
[ROW][C]39[/C][C]100.73[/C][C]101.063[/C][C]100.895[/C][C]1.00167[/C][C]0.996701[/C][/ROW]
[ROW][C]40[/C][C]101.12[/C][C]101.148[/C][C]101.052[/C][C]1.00095[/C][C]0.999719[/C][/ROW]
[ROW][C]41[/C][C]101.16[/C][C]101.316[/C][C]101.218[/C][C]1.00096[/C][C]0.998465[/C][/ROW]
[ROW][C]42[/C][C]101.33[/C][C]101.47[/C][C]101.378[/C][C]1.00091[/C][C]0.998623[/C][/ROW]
[ROW][C]43[/C][C]101.37[/C][C]101.521[/C][C]101.53[/C][C]0.999913[/C][C]0.998515[/C][/ROW]
[ROW][C]44[/C][C]101.61[/C][C]101.567[/C][C]101.673[/C][C]0.998953[/C][C]1.00042[/C][/ROW]
[ROW][C]45[/C][C]101.85[/C][C]101.692[/C][C]101.856[/C][C]0.998394[/C][C]1.00155[/C][/ROW]
[ROW][C]46[/C][C]102.27[/C][C]102.076[/C][C]102.07[/C][C]1.00005[/C][C]1.0019[/C][/ROW]
[ROW][C]47[/C][C]102.28[/C][C]102.227[/C][C]102.28[/C][C]0.999481[/C][C]1.00052[/C][/ROW]
[ROW][C]48[/C][C]102.23[/C][C]102.399[/C][C]102.489[/C][C]0.99912[/C][C]0.998354[/C][/ROW]
[ROW][C]49[/C][C]102.42[/C][C]102.632[/C][C]102.696[/C][C]0.99938[/C][C]0.997933[/C][/ROW]
[ROW][C]50[/C][C]102.53[/C][C]102.923[/C][C]102.901[/C][C]1.00021[/C][C]0.996182[/C][/ROW]
[ROW][C]51[/C][C]103.47[/C][C]103.248[/C][C]103.075[/C][C]1.00167[/C][C]1.00215[/C][/ROW]
[ROW][C]52[/C][C]103.53[/C][C]103.316[/C][C]103.218[/C][C]1.00095[/C][C]1.00207[/C][/ROW]
[ROW][C]53[/C][C]103.77[/C][C]103.454[/C][C]103.355[/C][C]1.00096[/C][C]1.00306[/C][/ROW]
[ROW][C]54[/C][C]103.74[/C][C]103.595[/C][C]103.501[/C][C]1.00091[/C][C]1.0014[/C][/ROW]
[ROW][C]55[/C][C]103.93[/C][C]NA[/C][C]NA[/C][C]0.999913[/C][C]NA[/C][/ROW]
[ROW][C]56[/C][C]103.97[/C][C]NA[/C][C]NA[/C][C]0.998953[/C][C]NA[/C][/ROW]
[ROW][C]57[/C][C]103.68[/C][C]NA[/C][C]NA[/C][C]0.998394[/C][C]NA[/C][/ROW]
[ROW][C]58[/C][C]103.86[/C][C]NA[/C][C]NA[/C][C]1.00005[/C][C]NA[/C][/ROW]
[ROW][C]59[/C][C]103.97[/C][C]NA[/C][C]NA[/C][C]0.999481[/C][C]NA[/C][/ROW]
[ROW][C]60[/C][C]104.05[/C][C]NA[/C][C]NA[/C][C]0.99912[/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
197.91NANA0.99938NA
298.51NANA1.00021NA
398.54NANA1.00167NA
498.52NANA1.00095NA
598.66NANA1.00096NA
698.53NANA1.00091NA
798.7198.821998.83040.9999130.998868
898.9298.831998.93540.9989531.00089
998.9698.872299.03120.9983941.00089
1099.2599.139699.13461.000051.00111
1199.3299.192299.24370.9994811.00129
1299.4199.28399.37040.999121.00128
1399.3699.44299.50370.999380.999175
1499.5899.638199.61671.000210.999417
1599.7799.877299.71041.001670.998926
1699.7799.888999.79381.000950.998809
17100.0399.968899.87291.000961.00061
18100.2100.04699.9551.000911.00154
19100.24100.04100.0480.9999131.002
20100.1100.044100.1490.9989531.00056
21100.03100.079100.240.9983940.99951
22100.18100.315100.311.000050.998649
23100.29100.297100.3490.9994810.999929
24100.41100.277100.3660.999121.00132
25100.6100.319100.3810.999381.00281
26100.75100.412100.3911.000211.00336
27100.79100.561100.3931.001671.00228
28100.44100.494100.3981.000950.999462
29100.29100.499100.4021.000960.997925
30100.34100.492100.4011.000910.998486
31100.46100.393100.4010.9999131.00067
32100.12100.302100.4080.9989530.998181
33100.06100.25100.4110.9983940.998109
34100.28100.442100.4371.000050.99839
35100.28100.449100.5010.9994810.998317
36100.4100.49100.5790.999120.999102
37100.61100.595100.6580.999381.00014
38100.89100.78100.7581.000211.0011
39100.73101.063100.8951.001670.996701
40101.12101.148101.0521.000950.999719
41101.16101.316101.2181.000960.998465
42101.33101.47101.3781.000910.998623
43101.37101.521101.530.9999130.998515
44101.61101.567101.6730.9989531.00042
45101.85101.692101.8560.9983941.00155
46102.27102.076102.071.000051.0019
47102.28102.227102.280.9994811.00052
48102.23102.399102.4890.999120.998354
49102.42102.632102.6960.999380.997933
50102.53102.923102.9011.000210.996182
51103.47103.248103.0751.001671.00215
52103.53103.316103.2181.000951.00207
53103.77103.454103.3551.000961.00306
54103.74103.595103.5011.000911.0014
55103.93NANA0.999913NA
56103.97NANA0.998953NA
57103.68NANA0.998394NA
58103.86NANA1.00005NA
59103.97NANA0.999481NA
60104.05NANA0.99912NA



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