Home » date » 2011 » May » 20 »

Pieter De Bock Oef 9.2

*Unverified author*
R Software Module: /rwasp_decompose.wasp (opens new window with default values)
Title produced by software: Classical Decomposition
Date of computation: Fri, 20 May 2011 00:30:41 +0000
 
Cite this page as follows:
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL http://www.freestatistics.org/blog/date/2011/May/20/t1305851226iz9ffwjfksbvtxw.htm/, Retrieved Fri, 20 May 2011 02:27:10 +0200
 
Original text written by user:
 
IsPrivate?
No (this computation is public)
 
User-defined keywords:
KDGP2W92
 
Dataseries X:
» Textbox « » Textfile « » CSV «
193.230 199.068 195.076 191.563 191.067 186.665 185.508 184.371 183.046 175.714 175.768 171.029 170.465 170.102 156.389 124.291 99.360 86.675 85.056 128.236 164.257 162.401 152.779 156.005 153.387 153.190 148.840 144.211 145.953 145.542 150.271 147.489 143.824 134.754 131.736 126.304 125.511 125.495 130.133 126.257 110.323 98.417 105.749 120.665 124.075 127.245 146.731 144.979 148.210 144.670 142.970 142.524 146.142 146.522 148.128 148.798 150.181 152.388 155.694 160.662 155.520 158.262 154.338 158.196 160.371 154.856 150.636 145.899 141.242 140.834 141.119 139.104 134.437 129.425 123.155 119.273 120.472 121.523 121.983 123.658 124.794 124.827 120.382 117.395 115.790 114.283 117.271 117.448 118.764 120.550 123.554 125.412 124.182 119.828 115.361 114.226 115.214 115.864 114.276 113.469
 
Output produced by software:


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' @ www.yougetit.org


Classical Decomposition by Moving Averages
tObservationsFitTrendSeasonalRandom
1193.23NANA4.49186259920636NA
2199.068NANA4.08401140873015NA
3195.076NANA1.59519593253968NA
4191.563NANA-3.56405406746032NA
5191.067NANA-7.27397668650793NA
6186.665NANA-10.4762981150794NA
7185.508176.864041170635185.060208333333-8.196167162698428.64395882936506
8184.371183.186017361111182.904750.2812673611111121.1849826388889
9183.046185.56894593254180.0858755.48307093253968-2.52294593253967
10175.714180.000791170635175.6709166666674.32987450396826-4.2867911706349
11175.768174.040362599206169.0467916666674.993570932539681.72763740079364
12171.029165.311059027778161.0594166666674.251642361111125.71794097222221
13170.465157.199529265873152.7076666666674.4918625992063613.265470734127
14170.102150.267219742064146.1832083333334.0840114087301519.8347802579365
15156.389144.65657093254143.0613751.5951959325396811.7324290674603
16124.291138.159737599206141.723791666667-3.56405406746032-13.8687375992063
1799.36132.937231646825140.211208333333-7.27397668650793-33.5772316468254
1886.675128.151035218254138.627333333333-10.4762981150794-41.476035218254
1985.056129.093582837302137.28975-8.19616716269842-44.0375828373016
20128.236136.154767361111135.87350.281267361111112-7.91876736111112
21164.257140.337362599206134.8542916666675.4830709325396823.9196374007937
22162.401139.699624503968135.369754.3298745039682622.7013754960318
23152.779143.13469593254138.1411254.993570932539689.64430406746033
24156.005146.786934027778142.5352916666674.251642361111129.2180659722222
25153.387152.197237599206147.7053754.491862599206361.18976240079365
26153.19155.30888640873151.2248754.08401140873015-2.11888640873016
27148.84152.770904265873151.1757083333331.59519593253968-3.93090426587301
28144.211145.60832093254149.172375-3.56405406746032-1.39732093253966
29145.953139.869648313492147.143625-7.273976686507936.08335168650794
30145.542134.552993551587145.029291666667-10.476298115079410.9890064484127
31150.271134.434082837302142.63025-8.1961671626984215.8369171626984
32147.489140.596059027778140.3147916666670.2812673611111126.89294097222225
33143.824143.86444593254138.3813755.48307093253968-0.0404459325396545
34134.754141.183707837302136.8538333333334.32987450396826-6.42970783730158
35131.736139.614737599206134.6211666666674.99357093253968-7.87873759920635
36126.304135.424684027778131.1730416666674.25164236111112-9.12068402777776
37125.511131.846279265873127.3544166666674.49186259920636-6.33527926587303
38125.495128.465678075397124.3816666666674.08401140873015-2.9706780753968
39130.133124.03632093254122.4411251.595195932539686.09667906746031
40126.257117.74132093254121.305375-3.564054067460328.51567906746033
41110.323114.343314980159121.617291666667-7.27397668650793-4.02031498015873
4298.417112.543910218254123.020208333333-10.4762981150794-14.1269102182539
43105.749116.547957837302124.744125-8.19616716269842-10.7989578373016
44120.665126.770142361111126.4888750.281267361111112-6.1051423611111
45124.075133.305779265873127.8227083333335.48307093253968-9.23077926587304
46127.245133.365249503968129.0353754.32987450396826-6.12024950396827
47146.731136.19919593254131.2056254.9935709325396810.5318040674603
48144.979138.954100694444134.7024583333334.251642361111126.02489930555555
49148.21142.964487599206138.4726254.491862599206365.24551240079367
50144.67145.49463640873141.4106254.08401140873015-0.824636408730157
51142.97145.265779265873143.6705833333331.59519593253968-2.29577926587302
52142.524142.241904265873145.805958333333-3.564054067460320.282095734126983
53146.142139.953064980159147.227041666667-7.273976686507936.18893501984127
54146.522137.777660218254148.253958333333-10.47629811507948.74433978174602
55148.128141.015832837302149.212-8.196167162698427.1121671626984
56148.798150.364184027778150.0829166666670.281267361111112-1.56618402777775
57150.181156.605987599206151.1229166666675.48307093253968-6.42498759920636
58152.388156.579457837302152.2495833333334.32987450396826-4.19145783730158
59155.694158.489029265873153.4954583333334.99357093253968-2.79502926587301
60160.662158.687225694444154.4355833333334.251642361111121.97477430555557
61155.52159.37919593254154.8873333333334.49186259920636-3.85919593253965
62158.262158.955053075397154.8710416666674.08401140873015-0.693053075396847
63154.338155.972987599206154.3777916666671.59519593253968-1.6349875992064
64158.196149.959862599206153.523916666667-3.564054067460328.23613740079364
65160.371145.161231646825152.435208333333-7.2739766865079315.2097683531746
66154.856140.453368551587150.929666666667-10.476298115079414.4026314484127
67150.636140.956791170635149.152958333333-8.196167162698429.67920882936508
68145.899147.354225694444147.0729583333330.281267361111112-1.45522569444444
69141.242150.05519593254144.5721255.48307093253968-8.81319593253966
70140.834145.980916170635141.6510416666674.32987450396826-5.14691617063491
71141.119143.360362599206138.3667916666674.99357093253968-2.24136259920635
72139.104139.567100694444135.3154583333334.25164236111112-0.463100694444449
73134.437137.22457093254132.7327083333334.49186259920636-2.78757093253967
74129.425134.69613640873130.6121254.08401140873015-5.27113640873013
75123.155130.595279265873129.0000833333331.59519593253968-7.440279265873
76119.273124.083737599206127.647791666667-3.56405406746032-4.81073759920635
77120.472118.842814980159126.116791666667-7.273976686507931.62918501984126
78121.523113.871910218254124.348208333333-10.47629811507947.65108978174602
79121.983114.470541170635122.666708333333-8.196167162698427.51245882936512
80123.658121.540100694444121.2588333333330.2812673611111122.11789930555557
81124.794125.86582093254120.382755.48307093253968-1.07182093253967
82124.827124.391416170635120.0615416666674.329874503968260.435583829365072
83120.382124.907904265873119.9143333333334.99357093253968-4.52590426587301
84117.395124.054267361111119.8026254.25164236111112-6.6592673611111
85115.79124.319404265873119.8275416666674.49186259920636-8.52940426587301
86114.283124.050094742063119.9660833333334.08401140873015-9.7670947420635
87117.271121.608862599206120.0136666666671.59519593253968-4.33786259920633
88117.448116.21582093254119.779875-3.564054067460321.23217906746032
89118.764112.088398313492119.362375-7.273976686507936.67560168650795
90120.55108.544826884921119.021125-10.476298115079412.0051731150794
91123.554110.668916170635118.865083333333-8.1961671626984212.8850838293651
92125.412119.188225694444118.9069583333330.2812673611111126.22377430555557
93124.182124.331112599206118.8480416666675.48307093253968-0.149112599206362
94119.828122.887332837302118.5574583333334.32987450396826-3.05933283730158
95115.361NANA4.99357093253968NA
96114.226NANA4.25164236111112NA
97115.214NANANANA
98115.864NANANANA
99114.276NANANANA
100113.469NANANANA
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2011/May/20/t1305851226iz9ffwjfksbvtxw/1kpis1305851439.png (open in new window)
http://www.freestatistics.org/blog/date/2011/May/20/t1305851226iz9ffwjfksbvtxw/1kpis1305851439.ps (open in new window)


http://www.freestatistics.org/blog/date/2011/May/20/t1305851226iz9ffwjfksbvtxw/2ue8w1305851439.png (open in new window)
http://www.freestatistics.org/blog/date/2011/May/20/t1305851226iz9ffwjfksbvtxw/2ue8w1305851439.ps (open in new window)


http://www.freestatistics.org/blog/date/2011/May/20/t1305851226iz9ffwjfksbvtxw/32zzg1305851439.png (open in new window)
http://www.freestatistics.org/blog/date/2011/May/20/t1305851226iz9ffwjfksbvtxw/32zzg1305851439.ps (open in new window)


http://www.freestatistics.org/blog/date/2011/May/20/t1305851226iz9ffwjfksbvtxw/4xilk1305851439.png (open in new window)
http://www.freestatistics.org/blog/date/2011/May/20/t1305851226iz9ffwjfksbvtxw/4xilk1305851439.ps (open in new window)


 
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,m$trend[i]+m$seasonal[i]) else a<-table.element(a,m$trend[i]*m$seasonal[i])
a<-table.element(a,m$trend[i])
a<-table.element(a,m$seasonal[i])
a<-table.element(a,m$random[i])
a<-table.row.end(a)
}
a<-table.end(a)
table.save(a,file='mytable.tab')
 





Copyright

Creative Commons License

This work is licensed under a Creative Commons Attribution-Noncommercial-Share Alike 3.0 License.

Software written by Ed van Stee & Patrick Wessa


Disclaimer

Information provided on this web site is provided "AS IS" without warranty of any kind, either express or implied, including, without limitation, warranties of merchantability, fitness for a particular purpose, and noninfringement. We use reasonable efforts to include accurate and timely information and periodically update the information, and software without notice. However, we make no warranties or representations as to the accuracy or completeness of such information (or software), and we assume no liability or responsibility for errors or omissions in the content of this web site, or any software bugs in online applications. Your use of this web site is AT YOUR OWN RISK. Under no circumstances and under no legal theory shall we be liable to you or any other person for any direct, indirect, special, incidental, exemplary, or consequential damages arising from your access to, or use of, this web site.


Privacy Policy

We may request personal information to be submitted to our servers in order to be able to:

  • personalize online software applications according to your needs
  • enforce strict security rules with respect to the data that you upload (e.g. statistical data)
  • manage user sessions of online applications
  • alert you about important changes or upgrades in resources or applications

We NEVER allow other companies to directly offer registered users information about their products and services. Banner references and hyperlinks of third parties NEVER contain any personal data of the visitor.

We do NOT sell, nor transmit by any means, personal information, nor statistical data series uploaded by you to third parties.

We carefully protect your data from loss, misuse, alteration, and destruction. However, at any time, and under any circumstance you are solely responsible for managing your passwords, and keeping them secret.

We store a unique ANONYMOUS USER ID in the form of a small 'Cookie' on your computer. This allows us to track your progress when using this website which is necessary to create state-dependent features. The cookie is used for NO OTHER PURPOSE. At any time you may opt to disallow cookies from this website - this will not affect other features of this website.

We examine cookies that are used by third-parties (banner and online ads) very closely: abuse from third-parties automatically results in termination of the advertising contract without refund. We have very good reason to believe that the cookies that are produced by third parties (banner ads) do NOT cause any privacy or security risk.

FreeStatistics.org is safe. There is no need to download any software to use the applications and services contained in this website. Hence, your system's security is not compromised by their use, and your personal data - other than data you submit in the account application form, and the user-agent information that is transmitted by your browser - is never transmitted to our servers.

As a general rule, we do not log on-line behavior of individuals (other than normal logging of webserver 'hits'). However, in cases of abuse, hacking, unauthorized access, Denial of Service attacks, illegal copying, hotlinking, non-compliance with international webstandards (such as robots.txt), or any other harmful behavior, our system engineers are empowered to log, track, identify, publish, and ban misbehaving individuals - even if this leads to ban entire blocks of IP addresses, or disclosing user's identity.


FreeStatistics.org is powered by