Home » date » 2009 » Dec » 01 »

*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: Tue, 01 Dec 2009 12:14:53 -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/01/t1259694947i3r5krfqf5v916t.htm/, Retrieved Tue, 01 Dec 2009 20:15:52 +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/01/t1259694947i3r5krfqf5v916t.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 «
90398 90269 90390 88219 87032 87175 92603 93571 94118 92159 89528 89955 89587 89488 88521 86587 85159 84915 91378 92729 92194 89664 86285 86858 87184 86629 85220 84816 84831 84957 90951 92134 91790 86625 83324 82719 83614 81640 78665 77828 75728 72187 79357 81329 77304 75576 72932 74291 74988 73302 70483 69848 66466 67610 75091 76207 73454 72008 71362 74250
 
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
190398NANA518.019097222224NA
290269NANA-197.189236111116NA
390390NANA-1843.56423611112NA
488219NANA-2370.90798611112NA
587032NANA-3695.52256944444NA
687175NANA-3971.44965277777NA
79260393334.706597222290417.6252917.08159722221-731.706597222219
89357194974.133680555590351.29166666674622.84201388888-1403.13368055555
99411894158.571180555590240.8753917.69618055556-40.5711805555475
109215991565.9253472222900951470.92534722222593.074652777781
118952888836.727430555589948.9583333333-1112.23090277777691.272569444453
128995589521.050347222289776.75-255.699652777773433.949652777766
138958790149.560763888989631.5416666667518.019097222224-562.560763888876
148948889348.227430555689545.4166666667-197.189236111116139.772569444423
158852187586.602430555589430.1666666667-1843.56423611112934.397569444453
168658786875.133680555589246.0416666667-2370.90798611112-288.133680555547
178515985311.435763888989006.9583333333-3695.52256944444-152.435763888891
188491584771.342013888988742.7916666667-3971.44965277777143.657986111109
199137891430.706597222288513.6252917.08159722221-52.706597222219
209272992917.217013888988294.3754622.84201388888-188.217013888891
219219491955.404513888988037.70833333333917.69618055556238.595486111124
228966489297.300347222287826.3751470.92534722222366.699652777781
238628586626.685763888987738.9166666667-1112.23090277777-341.685763888891
248685887471.300347222287727-255.699652777773-613.300347222219
258718488228.977430555587710.9583333333518.019097222224-1044.97743055555
268662987471.185763888987668.375-197.189236111116-842.185763888876
278522085783.185763888987626.75-1843.56423611112-563.18576388889
288481685112.383680555587483.2916666667-2370.90798611112-296.383680555547
298483183537.769097222287233.2916666667-3695.522569444441293.23090277778
308495782966.008680555586937.4583333333-3971.449652777771990.99131944445
319095189533.331597222286616.252917.081597222211417.66840277777
329213490882.467013888986259.6254622.842013888881251.53298611111
339179089696.321180555585778.6253917.696180555562093.67881944445
348662586685.258680555585214.33333333331470.92534722222-60.2586805555475
358332483431.644097222284543.875-1112.23090277777-107.644097222219
368271983376.800347222283632.5-255.699652777773-657.800347222219
378361483135.352430555582617.3333333333518.019097222224478.647569444453
388164081486.852430555681684.0416666667-197.189236111116153.147569444438
397866578786.685763888980630.25-1843.56423611112-121.685763888876
407782877195.383680555579566.2916666667-2370.90798611112632.616319444453
417572874977.394097222278672.9166666667-3695.52256944444750.605902777781
427218773917.300347222277888.75-3971.44965277777-1730.30034722222
437935780095.248263888977178.16666666672917.08159722221-738.24826388889
448132981094.175347222276471.33333333334622.84201388888234.824652777766
457730479700.6961805556757833917.69618055556-2396.69618055556
467557676580.508680555575109.58333333331470.92534722222-1004.50868055555
477293273278.935763888974391.1666666667-1112.23090277777-346.935763888891
487429173558.842013888973814.5416666667-255.699652777773732.15798611111
497498873964.102430555573446.0833333333518.0190972222241023.89756944445
507330272857.727430555573054.9166666667-197.189236111116444.272569444453
517048370837.519097222272681.0833333333-1843.56423611112-354.519097222204
526984870001.092013888972372-2370.90798611112-153.092013888876
536646668462.394097222272157.9166666667-3695.52256944444-1996.39409722222
546761068119.342013888972090.7916666667-3971.44965277777-509.34201388889
5575091NANA2917.08159722221NA
5676207NANA4622.84201388888NA
5773454NANA3917.69618055556NA
5872008NANA1470.92534722222NA
5971362NANA-1112.23090277777NA
6074250NANA-255.699652777773NA
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2009/Dec/01/t1259694947i3r5krfqf5v916t/1k3s81259694892.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/01/t1259694947i3r5krfqf5v916t/1k3s81259694892.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Dec/01/t1259694947i3r5krfqf5v916t/26x7g1259694892.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/01/t1259694947i3r5krfqf5v916t/26x7g1259694892.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Dec/01/t1259694947i3r5krfqf5v916t/3ma371259694892.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/01/t1259694947i3r5krfqf5v916t/3ma371259694892.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Dec/01/t1259694947i3r5krfqf5v916t/4d82s1259694892.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/01/t1259694947i3r5krfqf5v916t/4d82s1259694892.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