Home » date » 2010 » Jul » 02 »

additieve decompositie

*Unverified author*
R Software Module: /rwasp_decompose.wasp (opens new window with default values)
Title produced by software: Classical Decomposition
Date of computation: Fri, 02 Jul 2010 14:55:49 +0000
 
Cite this page as follows:
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL http://www.freestatistics.org/blog/date/2010/Jul/02/t12780826094a0kcfryn45zltq.htm/, Retrieved Fri, 02 Jul 2010 16:56:55 +0200
 
BibTeX entries for LaTeX users:
@Manual{KEY,
    author = {{YOUR NAME}},
    publisher = {Office for Research Development and Education},
    title = {Statistical Computations at FreeStatistics.org, URL http://www.freestatistics.org/blog/date/2010/Jul/02/t12780826094a0kcfryn45zltq.htm/},
    year = {2010},
}
@Manual{R,
    title = {R: A Language and Environment for Statistical Computing},
    author = {{R Development Core Team}},
    organization = {R Foundation for Statistical Computing},
    address = {Vienna, Austria},
    year = {2010},
    note = {{ISBN} 3-900051-07-0},
    url = {http://www.R-project.org},
}
 
Original text written by user:
 
IsPrivate?
No (this computation is public)
 
User-defined keywords:
Thomas Talboom
 
Dataseries X:
» Textbox « » Textfile « » CSV «
68 67 66 64 84 83 68 58 59 59 60 62 58 58 59 62 87 83 68 58 68 63 65 68 62 69 74 72 94 102 92 81 99 95 92 93 85 92 99 107 125 137 125 115 135 128 120 123 119 128 139 155 164 176 162 155 174 171 162 160 156 163 180 195 203 212 203 184 200 198 195 177 176 180 194 204 206 219 213 196 214 209 213 194 197 211 240 251 254 273 271 245 264 264 262 237 237 251 272 282 278 291 293 271 284 290 288 262 263 275 297 301 296 309 310 292 300 314 310 288
 
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'George Udny Yule' @ 72.249.76.132


Classical Decomposition by Moving Averages
tObservationsFitTrendSeasonalRandom
168NANA-18.460262345679NA
267NANA-12.4417438271605NA
366NANA-0.529706790123453NA
464NANA5.50733024691358NA
584NANA11.8360339506173NA
683NANA20.1878858024691NA
76875.73881172839566.08333333333339.65547839506172-7.73881172839505
85858.41473765432165.2916666666667-6.87692901234567-0.414737654320987
95970.604552469135864.6255.97955246913581-11.6045524691358
105965.840663580246964.251.59066358024692-6.8406635802469
116061.581404320987664.2916666666667-2.71026234567901-1.58140432098764
126250.678626543209964.4166666666667-13.738040123456811.3213734567901
135845.956404320987664.4166666666667-18.46026234567912.0435956790124
145851.974922839506264.4166666666667-12.44174382716056.02507716049385
155964.261959876543264.7916666666667-0.529706790123453-5.2619598765432
166270.840663580246965.33333333333335.50733024691358-8.84066358024691
178777.544367283950665.708333333333311.83603395061739.45563271604938
188386.354552469135866.166666666666720.1878858024691-3.35455246913579
196876.23881172839566.58333333333339.65547839506172-8.23881172839505
205860.331404320987767.2083333333333-6.87692901234567-2.33140432098766
216874.271219135802568.29166666666675.97955246913581-6.27121913580247
226370.923996913580369.33333333333331.59066358024692-7.92399691358025
236567.331404320987670.0416666666667-2.71026234567901-2.33140432098764
246857.386959876543271.125-13.738040123456810.6130401234568
256254.456404320987672.9166666666666-18.4602623456797.54359567901237
266962.433256172839574.875-12.44174382716056.56674382716051
277476.595293209876577.125-0.529706790123453-2.59529320987653
287285.257330246913679.755.50733024691358-13.2573302469136
299494.044367283950682.208333333333311.8360339506173-0.0443672839506206
30102104.56288580246984.37520.1878858024691-2.56288580246914
319296.030478395061786.3759.65547839506172-4.03047839506172
328181.41473765432188.2916666666667-6.87692901234567-0.414737654320987
339996.271219135802590.29166666666675.979552469135812.72878086419753
349594.382330246913692.79166666666671.590663580246920.617669753086417
359292.831404320987795.5416666666667-2.71026234567901-0.831404320987659
369384.553626543209998.2916666666667-13.73804012345688.44637345679013
378582.664737654321101.125-18.4602623456792.33526234567901
389291.4749228395062103.916666666667-12.44174382716050.525077160493836
3999106.303626543210106.833333333333-0.529706790123453-7.30362654320989
40107115.215663580247109.7083333333335.50733024691358-8.21566358024691
41125124.086033950617112.2511.83603395061730.913966049382708
42137134.854552469136114.66666666666720.18788580246912.14544753086419
43125126.988811728395117.3333333333339.65547839506172-1.98881172839508
44115113.373070987654120.25-6.876929012345671.62692901234566
45135129.396219135802123.4166666666675.979552469135815.6037808641975
46128128.673996913580127.0833333333331.59066358024692-0.673996913580254
47120127.998070987654130.708333333333-2.71026234567901-7.99807098765433
48123120.220293209877133.958333333333-13.73804012345682.77970679012347
49119118.664737654321137.125-18.4602623456790.335262345678984
50128127.891589506173140.333333333333-12.44174382716050.108410493827165
51139143.095293209877143.625-0.529706790123453-4.09529320987656
52155152.548996913580147.0416666666675.507330246913582.45100308641975
53164162.419367283951150.58333333333311.83603395061731.58063271604937
54176174.062885802469153.87520.18788580246911.93711419753086
55162166.613811728395156.9583333333339.65547839506172-4.61381172839506
56155153.081404320988159.958333333333-6.876929012345671.91859567901233
57174169.104552469136163.1255.979552469135814.8954475308642
58171168.090663580247166.51.590663580246922.90933641975312
59162167.081404320988169.791666666667-2.71026234567901-5.08140432098764
60160159.17862654321172.916666666667-13.73804012345680.821373456790155
61156157.664737654321176.125-18.460262345679-1.66473765432096
62163166.599922839506179.041666666667-12.4417438271605-3.59992283950615
63180180.80362654321181.333333333333-0.529706790123453-0.803626543209901
64195189.048996913580183.5416666666675.507330246913585.95100308641975
65203197.877700617284186.04166666666711.83603395061735.12229938271605
66212208.312885802469188.12520.18788580246913.68711419753089
67203199.322145061728189.6666666666679.655478395061723.67785493827162
68184184.331404320988191.208333333333-6.87692901234567-0.331404320987616
69200198.479552469136192.55.979552469135811.52044753086420
70198195.048996913580193.4583333333331.590663580246922.95100308641977
71195191.248070987654193.958333333333-2.710262345679013.75192901234567
72177180.636959876543194.375-13.7380401234568-3.63695987654319
73176176.623070987654195.083333333333-18.460262345679-0.62307098765433
74180183.558256172839196-12.4417438271605-3.55825617283949
75194196.55362654321197.083333333333-0.529706790123453-2.55362654320987
76204203.632330246914198.1255.507330246913580.36766975308646
77206211.169367283951199.33333333333311.8360339506173-5.16936728395061
78219220.979552469136200.79166666666720.1878858024691-1.97955246913577
79213212.030478395062202.3759.655478395061720.969521604938308
80196197.664737654321204.541666666667-6.87692901234567-1.66473765432096
81214213.729552469136207.755.979552469135810.270447530864203
82209213.215663580247211.6251.59066358024692-4.21566358024691
83213212.873070987654215.583333333333-2.710262345679010.12692901234567
84194206.095293209877219.833333333333-13.7380401234568-12.0952932098765
85197206.039737654321224.5-18.460262345679-9.03973765432099
86211216.516589506173228.958333333333-12.4417438271605-5.51658950617281
87240232.55362654321233.083333333333-0.5297067901234537.44637345679016
88251242.965663580247237.4583333333335.507330246913588.03433641975312
89254253.627700617284241.79166666666711.83603395061730.372299382716079
90273265.812885802469245.62520.18788580246917.18711419753089
91271258.738811728395249.0833333333339.6554783950617212.2611882716049
92245245.539737654321252.416666666667-6.87692901234567-0.539737654320959
93264261.396219135802255.4166666666675.979552469135812.60378086419757
94264259.632330246914258.0416666666671.590663580246924.36766975308643
95262257.623070987654260.333333333333-2.710262345679014.37692901234573
96237248.345293209877262.083333333333-13.7380401234568-11.3452932098766
97237245.289737654321263.75-18.460262345679-8.28973765432099
98251253.308256172839265.75-12.4417438271605-2.30825617283949
99272267.136959876543267.666666666667-0.5297067901234534.86304012345681
100282275.090663580247269.5833333333335.507330246913586.90933641975312
101278283.586033950617271.7511.8360339506173-5.58603395061726
102291294.062885802469273.87520.1878858024691-3.06288580246911
103293285.6554783950622769.655478395061727.34452160493828
104271271.206404320988278.083333333333-6.87692901234567-0.206404320987644
105284286.104552469136280.1255.97955246913581-2.10455246913574
106290283.54899691358281.9583333333331.590663580246926.45100308641975
107288280.789737654321283.5-2.710262345679017.2102623456791
108262271.261959876543285-13.7380401234568-9.26195987654319
109263267.998070987654286.458333333333-18.460262345679-4.99807098765427
110275275.599922839506288.041666666667-12.4417438271605-0.599922839506178
111297289.05362654321289.583333333333-0.5297067901234537.94637345679013
112301296.757330246914291.255.507330246913584.24266975308649
113296305.002700617284293.16666666666711.8360339506173-9.00270061728395
114309315.354552469136295.16666666666720.1878858024691-6.3545524691358
115310NANA9.65547839506172NA
116292NANA-6.87692901234567NA
117300NANA5.97955246913581NA
118314NANA1.59066358024692NA
119310NANA-2.71026234567901NA
120288NANA-13.7380401234568NA
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Jul/02/t12780826094a0kcfryn45zltq/1q9jz1278082546.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Jul/02/t12780826094a0kcfryn45zltq/1q9jz1278082546.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Jul/02/t12780826094a0kcfryn45zltq/2q9jz1278082546.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Jul/02/t12780826094a0kcfryn45zltq/2q9jz1278082546.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Jul/02/t12780826094a0kcfryn45zltq/31j0k1278082546.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Jul/02/t12780826094a0kcfryn45zltq/31j0k1278082546.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Jul/02/t12780826094a0kcfryn45zltq/41j0k1278082546.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Jul/02/t12780826094a0kcfryn45zltq/41j0k1278082546.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