Free Statistics

of Irreproducible Research!

Author's title

Author*Unverified author*
R Software Modulerwasp_decompose.wasp
Title produced by softwareClassical Decomposition
Date of computationThu, 21 Apr 2016 20:39:12 +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/2016/Apr/21/t1461267587lwoxjat75i0fiv9.htm/, Retrieved Mon, 06 May 2024 03:19:31 +0000
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL https://freestatistics.org/blog/index.php?pk=294578, Retrieved Mon, 06 May 2024 03:19:31 +0000
QR Codes:

Original text written by user:
IsPrivate?No (this computation is public)
User-defined keywords
Estimated Impact151
Family? (F = Feedback message, R = changed R code, M = changed R Module, P = changed Parameters, D = changed Data)
-       [Classical Decomposition] [] [2016-04-21 19:39:12] [bfab382a4ab6d7836f6b75894769f754] [Current]
Feedback Forum

Post a new message
Dataseries X:
100
99
99.3
99.5
100.7
102.9
101.2
99.5
99.5
99.5
99.4
99.5
99.7
99.8
99.8
100.1
100
100
100.1
100.1
100
99.9
99.9
99.8
100.4
102.2
103.1
103
102.9
102.8
103
103.5
103.6
103.2
103
103
106.1
104.8
105.3
106.3
107.9
106.1
106.8
108.7
110.8
111.8
111.3
111.7
110.8
110.3
110.5
110.5
112.5
113
113.5
112.8
109.5
111.5
111.5
111.2




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

\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
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=294578&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]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=294578&T=0

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=294578&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







Classical Decomposition by Moving Averages
tObservationsFitTrendSeasonalRandom
1100NANA1.00054NA
299NANA0.998512NA
399.3NANA1.00004NA
499.5NANA1.0007NA
5100.7NANA1.00604NA
6102.9NANA1.00039NA
7101.299.998199.98751.000111.01202
899.599.9341100.0080.9992580.995656
999.5100.245100.0621.001830.992563
1099.5100.177100.1081.000690.993242
1199.499.7595100.1040.9965570.996396
1299.599.488399.95420.995341.00012
1399.799.841599.78751.000540.998582
1499.899.618399.76670.9985121.00182
1599.899.816699.81251.000040.999833
16100.199.919899.851.00071.0018
17100100.49199.88751.006040.995114
1810099.959799.92081.000391.0004
19100.199.973199.96251.000111.00127
20100.1100.017100.0920.9992581.00083
21100100.513100.3291.001830.9949
2299.9100.656100.5871.000690.992485
2399.9100.482100.8290.9965570.994208
2499.8100.596101.0670.995340.992091
25100.4101.359101.3041.000540.990538
26102.2101.416101.5670.9985121.00773
27103.1101.863101.8581.000041.01215
28103102.217102.1461.00071.00766
29102.9103.031102.4121.006040.998726
30102.8102.715102.6751.000391.00083
31103103.057103.0461.000110.999449
32103.5103.315103.3920.9992581.00179
33103.6103.781103.5921.001830.998255
34103.2103.892103.8211.000690.993339
35103103.808104.1670.9965570.992216
36103104.025104.5120.995340.990142
37106.1104.865104.8081.000541.01178
38104.8105.027105.1830.9985120.99784
39105.3105.704105.71.000040.996175
40106.3106.433106.3581.00070.998754
41107.9107.709107.0621.006041.00177
42106.1107.813107.7711.000390.984114
43106.8108.341108.3291.000110.98578
44108.7108.673108.7540.9992581.00024
45110.8109.4109.21.001831.0128
46111.8109.667109.5921.000691.01945
47111.3109.58109.9580.9965571.0157
48111.7109.923110.4370.995341.01617
49110.8111.064111.0041.000540.997621
50110.3111.288111.4540.9985120.991119
51110.5111.575111.5711.000040.990361
52110.5111.582111.5041.00070.990302
53112.5112.174111.51.006041.00291
54113111.531111.4881.000391.01317
55113.5NANA1.00011NA
56112.8NANA0.999258NA
57109.5NANA1.00183NA
58111.5NANA1.00069NA
59111.5NANA0.996557NA
60111.2NANA0.99534NA

\begin{tabular}{lllllllll}
\hline
Classical Decomposition by Moving Averages \tabularnewline
t & Observations & Fit & Trend & Seasonal & Random \tabularnewline
1 & 100 & NA & NA & 1.00054 & NA \tabularnewline
2 & 99 & NA & NA & 0.998512 & NA \tabularnewline
3 & 99.3 & NA & NA & 1.00004 & NA \tabularnewline
4 & 99.5 & NA & NA & 1.0007 & NA \tabularnewline
5 & 100.7 & NA & NA & 1.00604 & NA \tabularnewline
6 & 102.9 & NA & NA & 1.00039 & NA \tabularnewline
7 & 101.2 & 99.9981 & 99.9875 & 1.00011 & 1.01202 \tabularnewline
8 & 99.5 & 99.9341 & 100.008 & 0.999258 & 0.995656 \tabularnewline
9 & 99.5 & 100.245 & 100.062 & 1.00183 & 0.992563 \tabularnewline
10 & 99.5 & 100.177 & 100.108 & 1.00069 & 0.993242 \tabularnewline
11 & 99.4 & 99.7595 & 100.104 & 0.996557 & 0.996396 \tabularnewline
12 & 99.5 & 99.4883 & 99.9542 & 0.99534 & 1.00012 \tabularnewline
13 & 99.7 & 99.8415 & 99.7875 & 1.00054 & 0.998582 \tabularnewline
14 & 99.8 & 99.6183 & 99.7667 & 0.998512 & 1.00182 \tabularnewline
15 & 99.8 & 99.8166 & 99.8125 & 1.00004 & 0.999833 \tabularnewline
16 & 100.1 & 99.9198 & 99.85 & 1.0007 & 1.0018 \tabularnewline
17 & 100 & 100.491 & 99.8875 & 1.00604 & 0.995114 \tabularnewline
18 & 100 & 99.9597 & 99.9208 & 1.00039 & 1.0004 \tabularnewline
19 & 100.1 & 99.9731 & 99.9625 & 1.00011 & 1.00127 \tabularnewline
20 & 100.1 & 100.017 & 100.092 & 0.999258 & 1.00083 \tabularnewline
21 & 100 & 100.513 & 100.329 & 1.00183 & 0.9949 \tabularnewline
22 & 99.9 & 100.656 & 100.587 & 1.00069 & 0.992485 \tabularnewline
23 & 99.9 & 100.482 & 100.829 & 0.996557 & 0.994208 \tabularnewline
24 & 99.8 & 100.596 & 101.067 & 0.99534 & 0.992091 \tabularnewline
25 & 100.4 & 101.359 & 101.304 & 1.00054 & 0.990538 \tabularnewline
26 & 102.2 & 101.416 & 101.567 & 0.998512 & 1.00773 \tabularnewline
27 & 103.1 & 101.863 & 101.858 & 1.00004 & 1.01215 \tabularnewline
28 & 103 & 102.217 & 102.146 & 1.0007 & 1.00766 \tabularnewline
29 & 102.9 & 103.031 & 102.412 & 1.00604 & 0.998726 \tabularnewline
30 & 102.8 & 102.715 & 102.675 & 1.00039 & 1.00083 \tabularnewline
31 & 103 & 103.057 & 103.046 & 1.00011 & 0.999449 \tabularnewline
32 & 103.5 & 103.315 & 103.392 & 0.999258 & 1.00179 \tabularnewline
33 & 103.6 & 103.781 & 103.592 & 1.00183 & 0.998255 \tabularnewline
34 & 103.2 & 103.892 & 103.821 & 1.00069 & 0.993339 \tabularnewline
35 & 103 & 103.808 & 104.167 & 0.996557 & 0.992216 \tabularnewline
36 & 103 & 104.025 & 104.512 & 0.99534 & 0.990142 \tabularnewline
37 & 106.1 & 104.865 & 104.808 & 1.00054 & 1.01178 \tabularnewline
38 & 104.8 & 105.027 & 105.183 & 0.998512 & 0.99784 \tabularnewline
39 & 105.3 & 105.704 & 105.7 & 1.00004 & 0.996175 \tabularnewline
40 & 106.3 & 106.433 & 106.358 & 1.0007 & 0.998754 \tabularnewline
41 & 107.9 & 107.709 & 107.062 & 1.00604 & 1.00177 \tabularnewline
42 & 106.1 & 107.813 & 107.771 & 1.00039 & 0.984114 \tabularnewline
43 & 106.8 & 108.341 & 108.329 & 1.00011 & 0.98578 \tabularnewline
44 & 108.7 & 108.673 & 108.754 & 0.999258 & 1.00024 \tabularnewline
45 & 110.8 & 109.4 & 109.2 & 1.00183 & 1.0128 \tabularnewline
46 & 111.8 & 109.667 & 109.592 & 1.00069 & 1.01945 \tabularnewline
47 & 111.3 & 109.58 & 109.958 & 0.996557 & 1.0157 \tabularnewline
48 & 111.7 & 109.923 & 110.437 & 0.99534 & 1.01617 \tabularnewline
49 & 110.8 & 111.064 & 111.004 & 1.00054 & 0.997621 \tabularnewline
50 & 110.3 & 111.288 & 111.454 & 0.998512 & 0.991119 \tabularnewline
51 & 110.5 & 111.575 & 111.571 & 1.00004 & 0.990361 \tabularnewline
52 & 110.5 & 111.582 & 111.504 & 1.0007 & 0.990302 \tabularnewline
53 & 112.5 & 112.174 & 111.5 & 1.00604 & 1.00291 \tabularnewline
54 & 113 & 111.531 & 111.488 & 1.00039 & 1.01317 \tabularnewline
55 & 113.5 & NA & NA & 1.00011 & NA \tabularnewline
56 & 112.8 & NA & NA & 0.999258 & NA \tabularnewline
57 & 109.5 & NA & NA & 1.00183 & NA \tabularnewline
58 & 111.5 & NA & NA & 1.00069 & NA \tabularnewline
59 & 111.5 & NA & NA & 0.996557 & NA \tabularnewline
60 & 111.2 & NA & NA & 0.99534 & NA \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=294578&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]100[/C][C]NA[/C][C]NA[/C][C]1.00054[/C][C]NA[/C][/ROW]
[ROW][C]2[/C][C]99[/C][C]NA[/C][C]NA[/C][C]0.998512[/C][C]NA[/C][/ROW]
[ROW][C]3[/C][C]99.3[/C][C]NA[/C][C]NA[/C][C]1.00004[/C][C]NA[/C][/ROW]
[ROW][C]4[/C][C]99.5[/C][C]NA[/C][C]NA[/C][C]1.0007[/C][C]NA[/C][/ROW]
[ROW][C]5[/C][C]100.7[/C][C]NA[/C][C]NA[/C][C]1.00604[/C][C]NA[/C][/ROW]
[ROW][C]6[/C][C]102.9[/C][C]NA[/C][C]NA[/C][C]1.00039[/C][C]NA[/C][/ROW]
[ROW][C]7[/C][C]101.2[/C][C]99.9981[/C][C]99.9875[/C][C]1.00011[/C][C]1.01202[/C][/ROW]
[ROW][C]8[/C][C]99.5[/C][C]99.9341[/C][C]100.008[/C][C]0.999258[/C][C]0.995656[/C][/ROW]
[ROW][C]9[/C][C]99.5[/C][C]100.245[/C][C]100.062[/C][C]1.00183[/C][C]0.992563[/C][/ROW]
[ROW][C]10[/C][C]99.5[/C][C]100.177[/C][C]100.108[/C][C]1.00069[/C][C]0.993242[/C][/ROW]
[ROW][C]11[/C][C]99.4[/C][C]99.7595[/C][C]100.104[/C][C]0.996557[/C][C]0.996396[/C][/ROW]
[ROW][C]12[/C][C]99.5[/C][C]99.4883[/C][C]99.9542[/C][C]0.99534[/C][C]1.00012[/C][/ROW]
[ROW][C]13[/C][C]99.7[/C][C]99.8415[/C][C]99.7875[/C][C]1.00054[/C][C]0.998582[/C][/ROW]
[ROW][C]14[/C][C]99.8[/C][C]99.6183[/C][C]99.7667[/C][C]0.998512[/C][C]1.00182[/C][/ROW]
[ROW][C]15[/C][C]99.8[/C][C]99.8166[/C][C]99.8125[/C][C]1.00004[/C][C]0.999833[/C][/ROW]
[ROW][C]16[/C][C]100.1[/C][C]99.9198[/C][C]99.85[/C][C]1.0007[/C][C]1.0018[/C][/ROW]
[ROW][C]17[/C][C]100[/C][C]100.491[/C][C]99.8875[/C][C]1.00604[/C][C]0.995114[/C][/ROW]
[ROW][C]18[/C][C]100[/C][C]99.9597[/C][C]99.9208[/C][C]1.00039[/C][C]1.0004[/C][/ROW]
[ROW][C]19[/C][C]100.1[/C][C]99.9731[/C][C]99.9625[/C][C]1.00011[/C][C]1.00127[/C][/ROW]
[ROW][C]20[/C][C]100.1[/C][C]100.017[/C][C]100.092[/C][C]0.999258[/C][C]1.00083[/C][/ROW]
[ROW][C]21[/C][C]100[/C][C]100.513[/C][C]100.329[/C][C]1.00183[/C][C]0.9949[/C][/ROW]
[ROW][C]22[/C][C]99.9[/C][C]100.656[/C][C]100.587[/C][C]1.00069[/C][C]0.992485[/C][/ROW]
[ROW][C]23[/C][C]99.9[/C][C]100.482[/C][C]100.829[/C][C]0.996557[/C][C]0.994208[/C][/ROW]
[ROW][C]24[/C][C]99.8[/C][C]100.596[/C][C]101.067[/C][C]0.99534[/C][C]0.992091[/C][/ROW]
[ROW][C]25[/C][C]100.4[/C][C]101.359[/C][C]101.304[/C][C]1.00054[/C][C]0.990538[/C][/ROW]
[ROW][C]26[/C][C]102.2[/C][C]101.416[/C][C]101.567[/C][C]0.998512[/C][C]1.00773[/C][/ROW]
[ROW][C]27[/C][C]103.1[/C][C]101.863[/C][C]101.858[/C][C]1.00004[/C][C]1.01215[/C][/ROW]
[ROW][C]28[/C][C]103[/C][C]102.217[/C][C]102.146[/C][C]1.0007[/C][C]1.00766[/C][/ROW]
[ROW][C]29[/C][C]102.9[/C][C]103.031[/C][C]102.412[/C][C]1.00604[/C][C]0.998726[/C][/ROW]
[ROW][C]30[/C][C]102.8[/C][C]102.715[/C][C]102.675[/C][C]1.00039[/C][C]1.00083[/C][/ROW]
[ROW][C]31[/C][C]103[/C][C]103.057[/C][C]103.046[/C][C]1.00011[/C][C]0.999449[/C][/ROW]
[ROW][C]32[/C][C]103.5[/C][C]103.315[/C][C]103.392[/C][C]0.999258[/C][C]1.00179[/C][/ROW]
[ROW][C]33[/C][C]103.6[/C][C]103.781[/C][C]103.592[/C][C]1.00183[/C][C]0.998255[/C][/ROW]
[ROW][C]34[/C][C]103.2[/C][C]103.892[/C][C]103.821[/C][C]1.00069[/C][C]0.993339[/C][/ROW]
[ROW][C]35[/C][C]103[/C][C]103.808[/C][C]104.167[/C][C]0.996557[/C][C]0.992216[/C][/ROW]
[ROW][C]36[/C][C]103[/C][C]104.025[/C][C]104.512[/C][C]0.99534[/C][C]0.990142[/C][/ROW]
[ROW][C]37[/C][C]106.1[/C][C]104.865[/C][C]104.808[/C][C]1.00054[/C][C]1.01178[/C][/ROW]
[ROW][C]38[/C][C]104.8[/C][C]105.027[/C][C]105.183[/C][C]0.998512[/C][C]0.99784[/C][/ROW]
[ROW][C]39[/C][C]105.3[/C][C]105.704[/C][C]105.7[/C][C]1.00004[/C][C]0.996175[/C][/ROW]
[ROW][C]40[/C][C]106.3[/C][C]106.433[/C][C]106.358[/C][C]1.0007[/C][C]0.998754[/C][/ROW]
[ROW][C]41[/C][C]107.9[/C][C]107.709[/C][C]107.062[/C][C]1.00604[/C][C]1.00177[/C][/ROW]
[ROW][C]42[/C][C]106.1[/C][C]107.813[/C][C]107.771[/C][C]1.00039[/C][C]0.984114[/C][/ROW]
[ROW][C]43[/C][C]106.8[/C][C]108.341[/C][C]108.329[/C][C]1.00011[/C][C]0.98578[/C][/ROW]
[ROW][C]44[/C][C]108.7[/C][C]108.673[/C][C]108.754[/C][C]0.999258[/C][C]1.00024[/C][/ROW]
[ROW][C]45[/C][C]110.8[/C][C]109.4[/C][C]109.2[/C][C]1.00183[/C][C]1.0128[/C][/ROW]
[ROW][C]46[/C][C]111.8[/C][C]109.667[/C][C]109.592[/C][C]1.00069[/C][C]1.01945[/C][/ROW]
[ROW][C]47[/C][C]111.3[/C][C]109.58[/C][C]109.958[/C][C]0.996557[/C][C]1.0157[/C][/ROW]
[ROW][C]48[/C][C]111.7[/C][C]109.923[/C][C]110.437[/C][C]0.99534[/C][C]1.01617[/C][/ROW]
[ROW][C]49[/C][C]110.8[/C][C]111.064[/C][C]111.004[/C][C]1.00054[/C][C]0.997621[/C][/ROW]
[ROW][C]50[/C][C]110.3[/C][C]111.288[/C][C]111.454[/C][C]0.998512[/C][C]0.991119[/C][/ROW]
[ROW][C]51[/C][C]110.5[/C][C]111.575[/C][C]111.571[/C][C]1.00004[/C][C]0.990361[/C][/ROW]
[ROW][C]52[/C][C]110.5[/C][C]111.582[/C][C]111.504[/C][C]1.0007[/C][C]0.990302[/C][/ROW]
[ROW][C]53[/C][C]112.5[/C][C]112.174[/C][C]111.5[/C][C]1.00604[/C][C]1.00291[/C][/ROW]
[ROW][C]54[/C][C]113[/C][C]111.531[/C][C]111.488[/C][C]1.00039[/C][C]1.01317[/C][/ROW]
[ROW][C]55[/C][C]113.5[/C][C]NA[/C][C]NA[/C][C]1.00011[/C][C]NA[/C][/ROW]
[ROW][C]56[/C][C]112.8[/C][C]NA[/C][C]NA[/C][C]0.999258[/C][C]NA[/C][/ROW]
[ROW][C]57[/C][C]109.5[/C][C]NA[/C][C]NA[/C][C]1.00183[/C][C]NA[/C][/ROW]
[ROW][C]58[/C][C]111.5[/C][C]NA[/C][C]NA[/C][C]1.00069[/C][C]NA[/C][/ROW]
[ROW][C]59[/C][C]111.5[/C][C]NA[/C][C]NA[/C][C]0.996557[/C][C]NA[/C][/ROW]
[ROW][C]60[/C][C]111.2[/C][C]NA[/C][C]NA[/C][C]0.99534[/C][C]NA[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=294578&T=1

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=294578&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
1100NANA1.00054NA
299NANA0.998512NA
399.3NANA1.00004NA
499.5NANA1.0007NA
5100.7NANA1.00604NA
6102.9NANA1.00039NA
7101.299.998199.98751.000111.01202
899.599.9341100.0080.9992580.995656
999.5100.245100.0621.001830.992563
1099.5100.177100.1081.000690.993242
1199.499.7595100.1040.9965570.996396
1299.599.488399.95420.995341.00012
1399.799.841599.78751.000540.998582
1499.899.618399.76670.9985121.00182
1599.899.816699.81251.000040.999833
16100.199.919899.851.00071.0018
17100100.49199.88751.006040.995114
1810099.959799.92081.000391.0004
19100.199.973199.96251.000111.00127
20100.1100.017100.0920.9992581.00083
21100100.513100.3291.001830.9949
2299.9100.656100.5871.000690.992485
2399.9100.482100.8290.9965570.994208
2499.8100.596101.0670.995340.992091
25100.4101.359101.3041.000540.990538
26102.2101.416101.5670.9985121.00773
27103.1101.863101.8581.000041.01215
28103102.217102.1461.00071.00766
29102.9103.031102.4121.006040.998726
30102.8102.715102.6751.000391.00083
31103103.057103.0461.000110.999449
32103.5103.315103.3920.9992581.00179
33103.6103.781103.5921.001830.998255
34103.2103.892103.8211.000690.993339
35103103.808104.1670.9965570.992216
36103104.025104.5120.995340.990142
37106.1104.865104.8081.000541.01178
38104.8105.027105.1830.9985120.99784
39105.3105.704105.71.000040.996175
40106.3106.433106.3581.00070.998754
41107.9107.709107.0621.006041.00177
42106.1107.813107.7711.000390.984114
43106.8108.341108.3291.000110.98578
44108.7108.673108.7540.9992581.00024
45110.8109.4109.21.001831.0128
46111.8109.667109.5921.000691.01945
47111.3109.58109.9580.9965571.0157
48111.7109.923110.4370.995341.01617
49110.8111.064111.0041.000540.997621
50110.3111.288111.4540.9985120.991119
51110.5111.575111.5711.000040.990361
52110.5111.582111.5041.00070.990302
53112.5112.174111.51.006041.00291
54113111.531111.4881.000391.01317
55113.5NANA1.00011NA
56112.8NANA0.999258NA
57109.5NANA1.00183NA
58111.5NANA1.00069NA
59111.5NANA0.996557NA
60111.2NANA0.99534NA



Parameters (Session):
par1 = multiplicative ; par2 = 12 ;
Parameters (R input):
par1 = multiplicative ; par2 = 12 ;
R code (references can be found in the software module):
par2 <- '12'
par1 <- 'additive'
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')