Home » date » 2009 » Dec » 18 »

*The author of this computation has been verified*
R Software Module: /rwasp_decompose.wasp (opens new window with default values)
Title produced by software: Classical Decomposition
Date of computation: Fri, 18 Dec 2009 02:43:47 -0700
 
Cite this page as follows:
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL http://www.freestatistics.org/blog/date/2009/Dec/18/t12611294598c0xornbfq9pdm9.htm/, Retrieved Fri, 18 Dec 2009 10:44:25 +0100
 
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/2009/Dec/18/t12611294598c0xornbfq9pdm9.htm/},
    year = {2009},
}
@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 = {2009},
    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:
 
Dataseries X:
» Textbox « » Textfile « » CSV «
20366 22782 19169 13807 29743 25591 29096 26482 22405 27044 17970 18730 19684 19785 18479 10698 31956 29506 34506 27165 26736 23691 18157 17328 18205 20995 17382 9367 31124 26551 30651 25859 25100 25778 20418 18688 20424 24776 19814 12738 31566 30111 30019 31934 25826 26835 20205 17789 20520 22518 15572 11509 25447 24090 27786 26195 20516 22759 19028 16971
 
Output produced by software:


Summary of computational transaction
Raw Inputview raw input (R code)
Raw Outputview raw output of R engine
Computing time1 seconds
R Server'Gwilym Jenkins' @ 72.249.127.135


Classical Decomposition by Moving Averages
tObservationsFitTrendSeasonalRandom
120366NANA0.861676041307918NA
222782NANA0.963091323170254NA
319169NANA0.778825705624943NA
413807NANA0.48645094526242NA
529743NANA1.31919634715688NA
625591NANA1.21080895344740NA
72909630569.228335751227371.344470613350530.951806819604012
82648227161.939186319122583.70833333331.202722723186620.974967207545272
92240524290.334792582522430.08333333331.082935557198070.922383334413397
102704425003.93503959922271.79166666671.122672814734591.0815897560592
111797018568.228591974122234.45833333330.835110453945130.967782139851905
121873017812.781343101522489.79166666670.7920385216152461.05149216392608
131968419713.711698389622878.33333333330.8616760413079180.998492840980724
141978522278.429131600023132.20833333330.9630913231702540.888078772660714
151847918178.66814820523341.1250.7788257056249431.01652111416230
161069811374.135195757823381.8750.486450945262420.94055502382195
173195630671.260104882923249.95833333331.319196347156881.04188741808207
182950628089.960514010823199.33333333331.210808953447401.05041087492035
193450631029.429422779123079.29166666671.344470613350531.11204107332598
202716527744.508005362623068.08333333331.202722723186620.979112694834936
212673624986.346499656723072.79166666671.082935557198071.07002438313130
222369125789.618897777422971.6251.122672814734590.918625439712942
231815719108.579851945522881.50.835110453945130.95020143520249
241732817998.052353949422723.70833333330.7920385216152460.962770840934778
251820519335.974463781322439.95833333330.8616760413079180.941509311263327
262099521404.624399848622224.91666666670.9630913231702540.980862808326059
271738217213.865354291022102.33333333330.7788257056249431.00976739635454
28936710760.842166518222121.1250.486450945262420.870470903210993
293112429421.101699893922302.29166666671.319196347156881.05788016769312
302655127186.495233246822453.16666666671.210808953447400.976624598801923
313065130388.116940210922602.29166666671.344470613350531.00865085060408
322585927484.970464388322852.29166666671.202722723186620.940841469468013
332510025027.904151664223111.16666666671.082935557198071.00288061868461
342577826217.731464462923352.95833333331.122672814734590.98322770736061
352041819634.977808082223511.83333333330.835110453945131.03987894458406
361868818754.350137276723678.58333333330.7920385216152460.996462146819747
372042420508.392427485923800.58333333330.8616760413079180.995884980854337
382477623140.556381057924027.3750.9630913231702541.07067434300244
391981418933.837023021624310.750.7788257056249431.0464862444896
401273811862.126569013524385.04166666670.486450945262421.07383780858269
413156632215.049630143224420.20833333331.319196347156880.979852595678266
423011129512.106080207824373.8751.210808953447401.02029316098839
433001932724.974925040824340.41666666671.344470613350530.917311627243747
443193429166.426944850024250.33333333331.202722723186621.09488899892960
452582625968.253193831223979.51.082935557198070.994522034548517
462683526665.210137202523751.54166666671.122672814734591.00636746764506
472020519579.477759163823445.3750.835110453945131.03194785113936
481778918169.00066819822939.54166666670.7920385216152460.97908521909721
492052019470.108700878222595.6250.8616760413079181.05392323767943
502251821441.743544595822263.45833333330.9630913231702541.05019444678861
511557216980.801761882821803.08333333330.7788257056249430.917035615771386
521150910415.8876399589214120.486450945262421.10494663516218
532544727957.893084839021193.1251.319196347156880.910190189324365
542409025560.1770072746211101.210808953447400.942481736067155
5527786NANA1.34447061335053NA
5626195NANA1.20272272318662NA
5720516NANA1.08293555719807NA
5822759NANA1.12267281473459NA
5919028NANA0.83511045394513NA
6016971NANA0.792038521615246NA
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2009/Dec/18/t12611294598c0xornbfq9pdm9/15smp1261129425.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/18/t12611294598c0xornbfq9pdm9/15smp1261129425.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Dec/18/t12611294598c0xornbfq9pdm9/2y8p01261129425.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/18/t12611294598c0xornbfq9pdm9/2y8p01261129425.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Dec/18/t12611294598c0xornbfq9pdm9/3v0z51261129425.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/18/t12611294598c0xornbfq9pdm9/3v0z51261129425.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Dec/18/t12611294598c0xornbfq9pdm9/4uj7l1261129425.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/18/t12611294598c0xornbfq9pdm9/4uj7l1261129425.ps (open in new window)


 
Parameters (Session):
par1 = FALSE ; par2 = 0.5 ; par3 = 1 ; par4 = 1 ; par5 = 12 ; par6 = 3 ; par7 = 1 ; par8 = 2 ; par9 = 1 ;
 
Parameters (R input):
par1 = multiplicative ; par2 = 12 ; par3 = 1 ; par4 = 1 ; par5 = 12 ; par6 = 3 ; par7 = 1 ; par8 = 2 ; par9 = 1 ;
 
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