Free Statistics

of Irreproducible Research!

Author's title

Author*Unverified author*
R Software Modulerwasp_decompose.wasp
Title produced by softwareClassical Decomposition
Date of computationSat, 26 Nov 2016 20:03:59 +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/26/t14801906522z09lguzrpabkp5.htm/, Retrieved Sat, 04 May 2024 01:51:01 +0200
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL https://freestatistics.org/blog/index.php?pk=, Retrieved Sat, 04 May 2024 01:51:01 +0200
QR Codes:

Original text written by user:
IsPrivate?No (this computation is public)
User-defined keywords
Estimated Impact0
Dataseries X:
37729
48191
52498
57319
44377
48081
52597
53331
39587
46278
50365
57176
39251
47946
50427
54317
41210
50592
55728
59099
47519
53203
53882
55163
45255
50423
52161
54562
40971
48014
48440
44967
27218
30269
33234
36811
27745
31891
32398
34093
28358
29532
30769
32080
23951
34628
22978
35704
23090
22111
28925
35968
28963
34074
39160
51314
34527
40722
50609
52435




Summary of computational transaction
Raw Inputview raw input (R code)
Raw Outputview raw output of R engine
Computing time2 seconds
R Server'Herman Ole Andreas Wold' @ wold.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 & 'Herman Ole Andreas Wold' @ wold.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]'Herman Ole Andreas Wold' @ wold.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'Herman Ole Andreas Wold' @ wold.wessa.net







Classical Decomposition by Moving Averages
tObservationsFitTrendSeasonalRandom
137729NANA-6327.45NA
248191NANA-856.835NA
35249851226.149765.21460.861271.89
45731956305.950582.55723.421013.08
54437744253.750581.1-6327.45123.326
64808149238.250095-856.835-1157.17
75259750458.648997.81460.862138.39
8533315389748173.65723.42-566.049
93958741341.847669.2-6327.45-1754.8
10462784701447870.9-856.835-736.04
115036549770.448309.51460.86594.638
125717654199.4484765723.422976.58
133925142364.848692.2-6327.45-3113.8
144794647485.848342.6-856.835460.21
15504274969148230.11460.86736.013
165431754529.248805.85723.42-212.174
174121043471.749799.1-6327.45-2261.67
185059250202.751059.5-856.835389.335
195572853906.752445.91460.861821.26
205909959284.353560.95723.42-185.299
21475194732953656.5-6327.45189.951
225320352076.952933.8-856.8351126.08
235388253619.652158.81460.86262.388
245516357251.751528.25723.42-2088.67
254525544638.250965.6-6327.45616.826
265042349818.550675.4-856.835604.46
275216151525.650064.81460.86635.388
285456254951.549228.15723.42-389.549
294097142134.448461.9-6327.45-1163.42
304801445940.546797.4-856.8352073.46
314844045339.743878.91460.863100.26
32449674566539941.65723.42-698.049
332721829495.335822.8-6327.45-2277.3
343026932045.732902.5-856.835-1776.67
353323433409.731948.91460.86-175.737
363681137940.932217.55723.42-1129.92
372774525988.332315.8-6327.451756.7
383189131014.731871.5-856.835876.335
393239833069.231608.41460.86-671.237
403409337113.531390.15723.42-3020.55
412835824564.230891.6-6327.453793.83
422953229579.530436.4-856.835-47.5402
433076931094.729633.91460.86-325.737
443208035443.4297205723.42-3363.42
452395123055.729383.1-6327.45895.326
463462828005.428862.2-856.8356622.58
472297830668.529207.61460.86-7690.49
483570433258.827535.45723.422445.2
492309020386.726714.1-6327.452703.33
502211126633.727490.5-856.835-4522.67
512892529718.528257.61460.86-793.487
523596836210.530487.15723.42-242.549
532896326934.433261.9-6327.452028.58
543407435602.736459.5-856.835-1528.67
553916040534.139073.21460.86-1374.11
565131446323.240599.85723.424990.83
573452736534.442861.9-6327.45-2007.42
584072243576.344433.1-856.835-2854.29
5950609NANA1460.86NA
6052435NANA5723.42NA

\begin{tabular}{lllllllll}
\hline
Classical Decomposition by Moving Averages \tabularnewline
t & Observations & Fit & Trend & Seasonal & Random \tabularnewline
1 & 37729 & NA & NA & -6327.45 & NA \tabularnewline
2 & 48191 & NA & NA & -856.835 & NA \tabularnewline
3 & 52498 & 51226.1 & 49765.2 & 1460.86 & 1271.89 \tabularnewline
4 & 57319 & 56305.9 & 50582.5 & 5723.42 & 1013.08 \tabularnewline
5 & 44377 & 44253.7 & 50581.1 & -6327.45 & 123.326 \tabularnewline
6 & 48081 & 49238.2 & 50095 & -856.835 & -1157.17 \tabularnewline
7 & 52597 & 50458.6 & 48997.8 & 1460.86 & 2138.39 \tabularnewline
8 & 53331 & 53897 & 48173.6 & 5723.42 & -566.049 \tabularnewline
9 & 39587 & 41341.8 & 47669.2 & -6327.45 & -1754.8 \tabularnewline
10 & 46278 & 47014 & 47870.9 & -856.835 & -736.04 \tabularnewline
11 & 50365 & 49770.4 & 48309.5 & 1460.86 & 594.638 \tabularnewline
12 & 57176 & 54199.4 & 48476 & 5723.42 & 2976.58 \tabularnewline
13 & 39251 & 42364.8 & 48692.2 & -6327.45 & -3113.8 \tabularnewline
14 & 47946 & 47485.8 & 48342.6 & -856.835 & 460.21 \tabularnewline
15 & 50427 & 49691 & 48230.1 & 1460.86 & 736.013 \tabularnewline
16 & 54317 & 54529.2 & 48805.8 & 5723.42 & -212.174 \tabularnewline
17 & 41210 & 43471.7 & 49799.1 & -6327.45 & -2261.67 \tabularnewline
18 & 50592 & 50202.7 & 51059.5 & -856.835 & 389.335 \tabularnewline
19 & 55728 & 53906.7 & 52445.9 & 1460.86 & 1821.26 \tabularnewline
20 & 59099 & 59284.3 & 53560.9 & 5723.42 & -185.299 \tabularnewline
21 & 47519 & 47329 & 53656.5 & -6327.45 & 189.951 \tabularnewline
22 & 53203 & 52076.9 & 52933.8 & -856.835 & 1126.08 \tabularnewline
23 & 53882 & 53619.6 & 52158.8 & 1460.86 & 262.388 \tabularnewline
24 & 55163 & 57251.7 & 51528.2 & 5723.42 & -2088.67 \tabularnewline
25 & 45255 & 44638.2 & 50965.6 & -6327.45 & 616.826 \tabularnewline
26 & 50423 & 49818.5 & 50675.4 & -856.835 & 604.46 \tabularnewline
27 & 52161 & 51525.6 & 50064.8 & 1460.86 & 635.388 \tabularnewline
28 & 54562 & 54951.5 & 49228.1 & 5723.42 & -389.549 \tabularnewline
29 & 40971 & 42134.4 & 48461.9 & -6327.45 & -1163.42 \tabularnewline
30 & 48014 & 45940.5 & 46797.4 & -856.835 & 2073.46 \tabularnewline
31 & 48440 & 45339.7 & 43878.9 & 1460.86 & 3100.26 \tabularnewline
32 & 44967 & 45665 & 39941.6 & 5723.42 & -698.049 \tabularnewline
33 & 27218 & 29495.3 & 35822.8 & -6327.45 & -2277.3 \tabularnewline
34 & 30269 & 32045.7 & 32902.5 & -856.835 & -1776.67 \tabularnewline
35 & 33234 & 33409.7 & 31948.9 & 1460.86 & -175.737 \tabularnewline
36 & 36811 & 37940.9 & 32217.5 & 5723.42 & -1129.92 \tabularnewline
37 & 27745 & 25988.3 & 32315.8 & -6327.45 & 1756.7 \tabularnewline
38 & 31891 & 31014.7 & 31871.5 & -856.835 & 876.335 \tabularnewline
39 & 32398 & 33069.2 & 31608.4 & 1460.86 & -671.237 \tabularnewline
40 & 34093 & 37113.5 & 31390.1 & 5723.42 & -3020.55 \tabularnewline
41 & 28358 & 24564.2 & 30891.6 & -6327.45 & 3793.83 \tabularnewline
42 & 29532 & 29579.5 & 30436.4 & -856.835 & -47.5402 \tabularnewline
43 & 30769 & 31094.7 & 29633.9 & 1460.86 & -325.737 \tabularnewline
44 & 32080 & 35443.4 & 29720 & 5723.42 & -3363.42 \tabularnewline
45 & 23951 & 23055.7 & 29383.1 & -6327.45 & 895.326 \tabularnewline
46 & 34628 & 28005.4 & 28862.2 & -856.835 & 6622.58 \tabularnewline
47 & 22978 & 30668.5 & 29207.6 & 1460.86 & -7690.49 \tabularnewline
48 & 35704 & 33258.8 & 27535.4 & 5723.42 & 2445.2 \tabularnewline
49 & 23090 & 20386.7 & 26714.1 & -6327.45 & 2703.33 \tabularnewline
50 & 22111 & 26633.7 & 27490.5 & -856.835 & -4522.67 \tabularnewline
51 & 28925 & 29718.5 & 28257.6 & 1460.86 & -793.487 \tabularnewline
52 & 35968 & 36210.5 & 30487.1 & 5723.42 & -242.549 \tabularnewline
53 & 28963 & 26934.4 & 33261.9 & -6327.45 & 2028.58 \tabularnewline
54 & 34074 & 35602.7 & 36459.5 & -856.835 & -1528.67 \tabularnewline
55 & 39160 & 40534.1 & 39073.2 & 1460.86 & -1374.11 \tabularnewline
56 & 51314 & 46323.2 & 40599.8 & 5723.42 & 4990.83 \tabularnewline
57 & 34527 & 36534.4 & 42861.9 & -6327.45 & -2007.42 \tabularnewline
58 & 40722 & 43576.3 & 44433.1 & -856.835 & -2854.29 \tabularnewline
59 & 50609 & NA & NA & 1460.86 & NA \tabularnewline
60 & 52435 & NA & NA & 5723.42 & 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]37729[/C][C]NA[/C][C]NA[/C][C]-6327.45[/C][C]NA[/C][/ROW]
[ROW][C]2[/C][C]48191[/C][C]NA[/C][C]NA[/C][C]-856.835[/C][C]NA[/C][/ROW]
[ROW][C]3[/C][C]52498[/C][C]51226.1[/C][C]49765.2[/C][C]1460.86[/C][C]1271.89[/C][/ROW]
[ROW][C]4[/C][C]57319[/C][C]56305.9[/C][C]50582.5[/C][C]5723.42[/C][C]1013.08[/C][/ROW]
[ROW][C]5[/C][C]44377[/C][C]44253.7[/C][C]50581.1[/C][C]-6327.45[/C][C]123.326[/C][/ROW]
[ROW][C]6[/C][C]48081[/C][C]49238.2[/C][C]50095[/C][C]-856.835[/C][C]-1157.17[/C][/ROW]
[ROW][C]7[/C][C]52597[/C][C]50458.6[/C][C]48997.8[/C][C]1460.86[/C][C]2138.39[/C][/ROW]
[ROW][C]8[/C][C]53331[/C][C]53897[/C][C]48173.6[/C][C]5723.42[/C][C]-566.049[/C][/ROW]
[ROW][C]9[/C][C]39587[/C][C]41341.8[/C][C]47669.2[/C][C]-6327.45[/C][C]-1754.8[/C][/ROW]
[ROW][C]10[/C][C]46278[/C][C]47014[/C][C]47870.9[/C][C]-856.835[/C][C]-736.04[/C][/ROW]
[ROW][C]11[/C][C]50365[/C][C]49770.4[/C][C]48309.5[/C][C]1460.86[/C][C]594.638[/C][/ROW]
[ROW][C]12[/C][C]57176[/C][C]54199.4[/C][C]48476[/C][C]5723.42[/C][C]2976.58[/C][/ROW]
[ROW][C]13[/C][C]39251[/C][C]42364.8[/C][C]48692.2[/C][C]-6327.45[/C][C]-3113.8[/C][/ROW]
[ROW][C]14[/C][C]47946[/C][C]47485.8[/C][C]48342.6[/C][C]-856.835[/C][C]460.21[/C][/ROW]
[ROW][C]15[/C][C]50427[/C][C]49691[/C][C]48230.1[/C][C]1460.86[/C][C]736.013[/C][/ROW]
[ROW][C]16[/C][C]54317[/C][C]54529.2[/C][C]48805.8[/C][C]5723.42[/C][C]-212.174[/C][/ROW]
[ROW][C]17[/C][C]41210[/C][C]43471.7[/C][C]49799.1[/C][C]-6327.45[/C][C]-2261.67[/C][/ROW]
[ROW][C]18[/C][C]50592[/C][C]50202.7[/C][C]51059.5[/C][C]-856.835[/C][C]389.335[/C][/ROW]
[ROW][C]19[/C][C]55728[/C][C]53906.7[/C][C]52445.9[/C][C]1460.86[/C][C]1821.26[/C][/ROW]
[ROW][C]20[/C][C]59099[/C][C]59284.3[/C][C]53560.9[/C][C]5723.42[/C][C]-185.299[/C][/ROW]
[ROW][C]21[/C][C]47519[/C][C]47329[/C][C]53656.5[/C][C]-6327.45[/C][C]189.951[/C][/ROW]
[ROW][C]22[/C][C]53203[/C][C]52076.9[/C][C]52933.8[/C][C]-856.835[/C][C]1126.08[/C][/ROW]
[ROW][C]23[/C][C]53882[/C][C]53619.6[/C][C]52158.8[/C][C]1460.86[/C][C]262.388[/C][/ROW]
[ROW][C]24[/C][C]55163[/C][C]57251.7[/C][C]51528.2[/C][C]5723.42[/C][C]-2088.67[/C][/ROW]
[ROW][C]25[/C][C]45255[/C][C]44638.2[/C][C]50965.6[/C][C]-6327.45[/C][C]616.826[/C][/ROW]
[ROW][C]26[/C][C]50423[/C][C]49818.5[/C][C]50675.4[/C][C]-856.835[/C][C]604.46[/C][/ROW]
[ROW][C]27[/C][C]52161[/C][C]51525.6[/C][C]50064.8[/C][C]1460.86[/C][C]635.388[/C][/ROW]
[ROW][C]28[/C][C]54562[/C][C]54951.5[/C][C]49228.1[/C][C]5723.42[/C][C]-389.549[/C][/ROW]
[ROW][C]29[/C][C]40971[/C][C]42134.4[/C][C]48461.9[/C][C]-6327.45[/C][C]-1163.42[/C][/ROW]
[ROW][C]30[/C][C]48014[/C][C]45940.5[/C][C]46797.4[/C][C]-856.835[/C][C]2073.46[/C][/ROW]
[ROW][C]31[/C][C]48440[/C][C]45339.7[/C][C]43878.9[/C][C]1460.86[/C][C]3100.26[/C][/ROW]
[ROW][C]32[/C][C]44967[/C][C]45665[/C][C]39941.6[/C][C]5723.42[/C][C]-698.049[/C][/ROW]
[ROW][C]33[/C][C]27218[/C][C]29495.3[/C][C]35822.8[/C][C]-6327.45[/C][C]-2277.3[/C][/ROW]
[ROW][C]34[/C][C]30269[/C][C]32045.7[/C][C]32902.5[/C][C]-856.835[/C][C]-1776.67[/C][/ROW]
[ROW][C]35[/C][C]33234[/C][C]33409.7[/C][C]31948.9[/C][C]1460.86[/C][C]-175.737[/C][/ROW]
[ROW][C]36[/C][C]36811[/C][C]37940.9[/C][C]32217.5[/C][C]5723.42[/C][C]-1129.92[/C][/ROW]
[ROW][C]37[/C][C]27745[/C][C]25988.3[/C][C]32315.8[/C][C]-6327.45[/C][C]1756.7[/C][/ROW]
[ROW][C]38[/C][C]31891[/C][C]31014.7[/C][C]31871.5[/C][C]-856.835[/C][C]876.335[/C][/ROW]
[ROW][C]39[/C][C]32398[/C][C]33069.2[/C][C]31608.4[/C][C]1460.86[/C][C]-671.237[/C][/ROW]
[ROW][C]40[/C][C]34093[/C][C]37113.5[/C][C]31390.1[/C][C]5723.42[/C][C]-3020.55[/C][/ROW]
[ROW][C]41[/C][C]28358[/C][C]24564.2[/C][C]30891.6[/C][C]-6327.45[/C][C]3793.83[/C][/ROW]
[ROW][C]42[/C][C]29532[/C][C]29579.5[/C][C]30436.4[/C][C]-856.835[/C][C]-47.5402[/C][/ROW]
[ROW][C]43[/C][C]30769[/C][C]31094.7[/C][C]29633.9[/C][C]1460.86[/C][C]-325.737[/C][/ROW]
[ROW][C]44[/C][C]32080[/C][C]35443.4[/C][C]29720[/C][C]5723.42[/C][C]-3363.42[/C][/ROW]
[ROW][C]45[/C][C]23951[/C][C]23055.7[/C][C]29383.1[/C][C]-6327.45[/C][C]895.326[/C][/ROW]
[ROW][C]46[/C][C]34628[/C][C]28005.4[/C][C]28862.2[/C][C]-856.835[/C][C]6622.58[/C][/ROW]
[ROW][C]47[/C][C]22978[/C][C]30668.5[/C][C]29207.6[/C][C]1460.86[/C][C]-7690.49[/C][/ROW]
[ROW][C]48[/C][C]35704[/C][C]33258.8[/C][C]27535.4[/C][C]5723.42[/C][C]2445.2[/C][/ROW]
[ROW][C]49[/C][C]23090[/C][C]20386.7[/C][C]26714.1[/C][C]-6327.45[/C][C]2703.33[/C][/ROW]
[ROW][C]50[/C][C]22111[/C][C]26633.7[/C][C]27490.5[/C][C]-856.835[/C][C]-4522.67[/C][/ROW]
[ROW][C]51[/C][C]28925[/C][C]29718.5[/C][C]28257.6[/C][C]1460.86[/C][C]-793.487[/C][/ROW]
[ROW][C]52[/C][C]35968[/C][C]36210.5[/C][C]30487.1[/C][C]5723.42[/C][C]-242.549[/C][/ROW]
[ROW][C]53[/C][C]28963[/C][C]26934.4[/C][C]33261.9[/C][C]-6327.45[/C][C]2028.58[/C][/ROW]
[ROW][C]54[/C][C]34074[/C][C]35602.7[/C][C]36459.5[/C][C]-856.835[/C][C]-1528.67[/C][/ROW]
[ROW][C]55[/C][C]39160[/C][C]40534.1[/C][C]39073.2[/C][C]1460.86[/C][C]-1374.11[/C][/ROW]
[ROW][C]56[/C][C]51314[/C][C]46323.2[/C][C]40599.8[/C][C]5723.42[/C][C]4990.83[/C][/ROW]
[ROW][C]57[/C][C]34527[/C][C]36534.4[/C][C]42861.9[/C][C]-6327.45[/C][C]-2007.42[/C][/ROW]
[ROW][C]58[/C][C]40722[/C][C]43576.3[/C][C]44433.1[/C][C]-856.835[/C][C]-2854.29[/C][/ROW]
[ROW][C]59[/C][C]50609[/C][C]NA[/C][C]NA[/C][C]1460.86[/C][C]NA[/C][/ROW]
[ROW][C]60[/C][C]52435[/C][C]NA[/C][C]NA[/C][C]5723.42[/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
137729NANA-6327.45NA
248191NANA-856.835NA
35249851226.149765.21460.861271.89
45731956305.950582.55723.421013.08
54437744253.750581.1-6327.45123.326
64808149238.250095-856.835-1157.17
75259750458.648997.81460.862138.39
8533315389748173.65723.42-566.049
93958741341.847669.2-6327.45-1754.8
10462784701447870.9-856.835-736.04
115036549770.448309.51460.86594.638
125717654199.4484765723.422976.58
133925142364.848692.2-6327.45-3113.8
144794647485.848342.6-856.835460.21
15504274969148230.11460.86736.013
165431754529.248805.85723.42-212.174
174121043471.749799.1-6327.45-2261.67
185059250202.751059.5-856.835389.335
195572853906.752445.91460.861821.26
205909959284.353560.95723.42-185.299
21475194732953656.5-6327.45189.951
225320352076.952933.8-856.8351126.08
235388253619.652158.81460.86262.388
245516357251.751528.25723.42-2088.67
254525544638.250965.6-6327.45616.826
265042349818.550675.4-856.835604.46
275216151525.650064.81460.86635.388
285456254951.549228.15723.42-389.549
294097142134.448461.9-6327.45-1163.42
304801445940.546797.4-856.8352073.46
314844045339.743878.91460.863100.26
32449674566539941.65723.42-698.049
332721829495.335822.8-6327.45-2277.3
343026932045.732902.5-856.835-1776.67
353323433409.731948.91460.86-175.737
363681137940.932217.55723.42-1129.92
372774525988.332315.8-6327.451756.7
383189131014.731871.5-856.835876.335
393239833069.231608.41460.86-671.237
403409337113.531390.15723.42-3020.55
412835824564.230891.6-6327.453793.83
422953229579.530436.4-856.835-47.5402
433076931094.729633.91460.86-325.737
443208035443.4297205723.42-3363.42
452395123055.729383.1-6327.45895.326
463462828005.428862.2-856.8356622.58
472297830668.529207.61460.86-7690.49
483570433258.827535.45723.422445.2
492309020386.726714.1-6327.452703.33
502211126633.727490.5-856.835-4522.67
512892529718.528257.61460.86-793.487
523596836210.530487.15723.42-242.549
532896326934.433261.9-6327.452028.58
543407435602.736459.5-856.835-1528.67
553916040534.139073.21460.86-1374.11
565131446323.240599.85723.424990.83
573452736534.442861.9-6327.45-2007.42
584072243576.344433.1-856.835-2854.29
5950609NANA1460.86NA
6052435NANA5723.42NA



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