Home » date » 2010 » May » 30 »

*Unverified author*
R Software Module: /rwasp_decompose.wasp (opens new window with default values)
Title produced by software: Classical Decomposition
Date of computation: Sun, 30 May 2010 11:21:00 +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/May/30/t12752184858lxygibdtppfl4h.htm/, Retrieved Sun, 30 May 2010 13:21:25 +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/May/30/t12752184858lxygibdtppfl4h.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:
KDGP2W52
 
Dataseries X:
» Textbox « » Textfile « » CSV «
77 70 67 76 85 106 108 120 108 111 109 104 104 117 111 110 116 118 115 111 112 97 106 93 95 97 81 71 75 70 72 80 78 80 81 99 87 100 95 128 112 104 102 108 103 99 96 85 78 74 106 100 109 87 107 106 109 83 84 83 65 68 61 75 66 78 68 68 174 64 48 45
 
Output produced by software:


Summary of computational transaction
Raw Inputview raw input (R code)
Raw Outputview raw output of R engine
Computing time3 seconds
R Server'Sir Ronald Aylmer Fisher' @ 193.190.124.24


Classical Decomposition by Moving Averages
tObservationsFitTrendSeasonalRandom
177NANA-9.25347222222222NA
270NANA-3.08680555555555NA
367NANA-3.60347222222222NA
476NANA2.23819444444445NA
585NANA1.93819444444444NA
6106NANA-1.26180555555556NA
7108100.58819444444496.20833333333334.379861111111127.41180555555559
8120107.98819444444499.29166666666668.6965277777777812.0118055555556
9108108.846527777778103.0833333333335.76319444444445-0.846527777777766
10111104.154861111111106.333333333333-2.178472222222226.84513888888888
11109108.229861111111109.041666666667-0.8118055555555570.770138888888894
12104108.013194444444110.833333333333-2.82013888888889-4.01319444444444
13104102.371527777778111.625-9.253472222222221.62847222222224
14117108.454861111111111.541666666667-3.086805555555558.5451388888889
15111107.729861111111111.333333333333-3.603472222222223.27013888888889
16110113.154861111111110.9166666666672.23819444444445-3.1548611111111
17116112.146527777778110.2083333333331.938194444444443.85347222222224
18118108.363194444444109.625-1.261805555555569.63680555555557
19115113.171527777778108.7916666666674.379861111111121.82847222222223
20111116.279861111111107.5833333333338.69652777777778-5.2798611111111
21112111.263194444444105.55.763194444444450.736805555555563
2297100.446527777778102.625-2.17847222222222-3.44652777777776
2310698.47986111111199.2916666666666-0.8118055555555577.52013888888891
249392.763194444444495.5833333333333-2.820138888888890.236805555555577
259582.538194444444491.7916666666667-9.2534722222222212.4618055555556
269785.621527777777888.7083333333333-3.0868055555555511.3784722222222
278182.396527777777886-3.60347222222222-1.39652777777776
287186.113194444444483.8752.23819444444445-15.1131944444444
297584.063194444444482.1251.93819444444444-9.06319444444443
307080.071527777777881.3333333333333-1.26180555555556-10.0715277777778
317285.629861111111181.254.37986111111112-13.6298611111111
328089.738194444444481.04166666666678.69652777777778-9.73819444444445
337887.513194444444581.755.76319444444445-9.51319444444445
348082.529861111111184.7083333333333-2.17847222222222-2.52986111111110
358187.813194444444488.625-0.811805555555557-6.81319444444445
369988.763194444444591.5833333333333-2.8201388888888910.2368055555555
378784.996527777777894.25-9.253472222222222.00347222222223
3810093.579861111111196.6666666666667-3.086805555555556.4201388888889
399595.271527777777898.875-3.60347222222222-0.271527777777763
40128102.946527777778100.7083333333332.2381944444444525.0534722222222
41112104.063194444444102.1251.938194444444447.93680555555557
42104100.904861111111102.166666666667-1.261805555555563.0951388888889
43102105.588194444444101.2083333333334.37986111111112-3.58819444444444
44108108.44652777777899.758.69652777777778-0.446527777777789
45103104.88819444444499.1255.76319444444445-1.88819444444445
469996.238194444444498.4166666666667-2.178472222222222.76180555555555
479696.313194444444497.125-0.811805555555557-0.313194444444449
488593.471527777777896.2916666666667-2.82013888888889-8.47152777777777
497886.538194444444495.7916666666667-9.25347222222222-8.53819444444443
507492.829861111111195.9166666666667-3.08680555555555-18.8298611111111
5110692.47986111111196.0833333333333-3.6034722222222213.5201388888889
5210097.904861111111195.66666666666672.238194444444452.09513888888890
5310996.438194444444494.51.9381944444444412.5618055555556
548792.65486111111193.9166666666667-1.26180555555556-5.65486111111109
5510797.671527777777893.29166666666674.379861111111129.32847222222223
56106101.19652777777892.58.696527777777784.80347222222225
5710996.138194444444490.3755.7631944444444512.8618055555556
588385.279861111111187.4583333333333-2.17847222222222-2.27986111111112
598483.813194444444484.625-0.8118055555555570.186805555555551
608379.638194444444482.4583333333333-2.820138888888893.36180555555556
616571.204861111111180.4583333333333-9.25347222222222-6.20486111111109
626874.163194444444477.25-3.08680555555555-6.16319444444444
636174.771527777777878.375-3.60347222222222-13.7715277777778
647582.529861111111180.29166666666672.23819444444445-7.5298611111111
656679.9381944444444781.93819444444444-13.9381944444444
667873.654861111111174.9166666666667-1.261805555555564.3451388888889
6768NANA4.37986111111112NA
6868NANA8.69652777777778NA
69174NANA5.76319444444445NA
7064NANA-2.17847222222222NA
7148NANA-0.811805555555557NA
7245NANA-2.82013888888889NA
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/May/30/t12752184858lxygibdtppfl4h/1bcp61275218456.png (open in new window)
http://www.freestatistics.org/blog/date/2010/May/30/t12752184858lxygibdtppfl4h/1bcp61275218456.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/May/30/t12752184858lxygibdtppfl4h/2bcp61275218456.png (open in new window)
http://www.freestatistics.org/blog/date/2010/May/30/t12752184858lxygibdtppfl4h/2bcp61275218456.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/May/30/t12752184858lxygibdtppfl4h/3l4o91275218456.png (open in new window)
http://www.freestatistics.org/blog/date/2010/May/30/t12752184858lxygibdtppfl4h/3l4o91275218456.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/May/30/t12752184858lxygibdtppfl4h/4l4o91275218456.png (open in new window)
http://www.freestatistics.org/blog/date/2010/May/30/t12752184858lxygibdtppfl4h/4l4o91275218456.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