Home » date » 2009 » Jun » 06 »

*Unverified author*
R Software Module: rwasp_decompose.wasp (opens new window with default values)
Title produced by software: Classical Decomposition
Date of computation: Sat, 06 Jun 2009 09:18:22 -0600
 
Cite this page as follows:
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL http://www.freestatistics.org/blog/date/2009/Jun/06/t1244301521gu3n2cz8y7x2ffa.htm/, Retrieved Sat, 06 Jun 2009 17:18:46 +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/2009/Jun/06/t1244301521gu3n2cz8y7x2ffa.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 «
3851,3 3851,8 3854,1 3858,4 3861,6 3856,3 3855,8 3860,4 3855,1 3839,5 3833 3833,6 3826,8 3818,2 3811,4 3806,8 3810,3 3818,2 3858,9 3867,8 3872,3 3873,3 3876,7 3882,6 3883,5 3882,2 3888,1 3893,7 3901,9 3914,3 3930,3 3948,3 3971,5 3990,1 3993 3998 4015,8 4041,2 4060,7 4076,7 4103 4125,3 4139,7 4146,7 4158 4155,1 4144,8 4148,2 4142,5 4142,1 4145,4 4146,3 4143,5 4149,2 4158,9 4166,1 4179,1 4194,4 4211,7 4226,3 4235,8 4243,6 4258,7 4278,2 4298 4315,1 4334,3 4356 4374 4395,5 4417,8 4432,8 4446,3
 
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
13851.3NANA0.999161804058414NA
23851.8NANA0.998270904092836NA
33854.1NANA0.997989468309282NA
43858.4NANA0.997597499163265NA
53861.6NANA0.997964223363847NA
63856.3NANA0.99877111874649NA
73855.83854.879286259393849.88751.001296605747411.00023884372823
83860.43855.411644104643847.466666666671.002064989284201.00129385818061
93855.13856.581136236563844.28751.003197897201120.999615945786114
103839.53850.9754097073840.358333333331.002764605657110.997020129061828
1138333839.2336821833836.070833333331.000824502202140.998376321240375
123833.63832.715203155813832.345833333331.000096382173881.00023085379354
133826.83827.676465644833830.88750.9991618040584140.99977101887981
143818.23824.700271623483831.3250.9982709040928360.9983004494047
153811.43824.644938875083832.350.9979894683092820.996536949419683
163806.83825.262670604063834.4750.9975974991632650.9951734894584
173810.33829.89145818773837.704166666670.9979642233638470.994884591795463
183818.23836.845837405893841.566666666670.998771118746490.995140321452557
193858.93850.957541220213845.970833333331.001296605747411.00206246334704
203867.83858.9522737334438511.002064989284201.00229277939683
213872.33869.196349793873856.86251.003197897201121.00080214337179
223873.33874.360715948093863.679166666671.002764605657110.999726221685108
233876.73874.308410883093871.116666666671.000824502202141.00061729445962
243882.63879.311360428593878.93751.000096382173881.00084773797869
253883.53882.659507087333885.916666666670.9991618040584141.00021647350512
263882.23885.515766993243892.245833333330.9982709040928360.999146634014097
273888.13891.892795881323899.733333333330.9979894683092820.999025462395744
283893.73899.342598229433908.733333333330.9975974991632650.998552936017474
293901.93910.46875285583918.445833333330.9979642233638470.99780876580345
303914.33923.272831548083928.10.998771118746490.997712921855465
313930.33943.527412421563938.420833333331.001296605747410.99664579168896
323948.33958.716193958263950.558333333331.002064989284200.997368794970915
333971.53977.052663716703964.3751.003197897201120.998603824443322
343990.13990.192562459063979.191666666671.002764605657110.999976802508247
3539933998.489881095913995.195833333331.000824502202140.998627011382005
3639984012.75338728844012.366666666671.000096382173880.99632337553184
374015.84026.505501478274029.883333333330.9991618040584140.997341242555278
384041.24039.877565000704046.8750.9982709040928361.00032734531629
394060.74054.743885662144062.91250.9979894683092821.00146892492000
404076.74067.761996025664077.558333333330.9975974991632651.00219727800768
4141034082.430463094184090.758333333330.9979642233638471.00503855168919
424125.34098.299147015754103.341666666670.998771118746491.00658830700631
434139.74120.214542644074114.879166666671.001296605747411.00472923367321
444146.74132.879264366654124.36251.002064989284201.00334409372965
4541584145.309851033524132.095833333331.003197897201121.00306132699907
464155.14149.96638962714138.5251.002764605657111.00123702456621
474144.84146.528505379984143.11251.000824502202140.99958314397749
484148.24146.195414148214145.795833333331.000096382173881.00048347597051
494142.54144.115172164314147.591666666670.9991618040584140.99961024920949
504142.14142.025635261994149.20.9982709040928361.00001795371264
514145.44142.542009136654150.88750.9979894683092821.00068991234296
524146.34143.425609680954153.404166666670.9975974991632651.00069372316287
534143.54149.364755192054157.829166666670.9979642233638470.998586589625626
544149.24158.753930524214163.870833333330.998771118746490.997702693959822
554158.94176.420658780034171.01251.001296605747410.995804862533855
564166.14187.759023613114179.129166666671.002064989284200.994828015773835
574179.14201.472213311834188.079166666671.003197897201120.99467514904872
584194.44209.902465744394198.295833333331.002764605657110.996317618787957
594211.74213.700509886114210.229166666671.000824502202140.999525236812294
604226.34223.98624440834223.579166666671.000096382173881.0005477658917
614235.84234.247893238754237.80.9991618040584141.00036656020157
624243.64245.666952417334253.020833333330.9982709040928360.999513161903537
634258.74260.471097975194269.054166666670.9979894683092820.999584295272879
644278.24275.258119195384285.554166666670.9975974991632651.00068811770485
6542984293.761861944274302.520833333330.9979642233638471.00098704543754
664315.14314.404086288194319.71250.998771118746491.00016130007711
674334.34342.710992579534337.08751.001296605747410.998063193108199
684356NANA1.00206498928420NA
694374NANA1.00319789720112NA
704395.5NANA1.00276460565711NA
714417.8NANA1.00082450220214NA
724432.8NANA1.00009638217388NA
734446.3NANANANA
 
Charts produced by software:
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2009/Jun/06/t1244301521gu3n2cz8y7x2ffa/15hrk1244301500.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2009/Jun/06/t1244301521gu3n2cz8y7x2ffa/15hrk1244301500.ps (open in new window)


http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2009/Jun/06/t1244301521gu3n2cz8y7x2ffa/2bidj1244301500.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2009/Jun/06/t1244301521gu3n2cz8y7x2ffa/2bidj1244301500.ps (open in new window)


http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2009/Jun/06/t1244301521gu3n2cz8y7x2ffa/3qcz81244301500.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2009/Jun/06/t1244301521gu3n2cz8y7x2ffa/3qcz81244301500.ps (open in new window)


http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2009/Jun/06/t1244301521gu3n2cz8y7x2ffa/45ecb1244301500.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2009/Jun/06/t1244301521gu3n2cz8y7x2ffa/45ecb1244301500.ps (open in new window)


 
Parameters (Session):
par1 = multiplicative ; par2 = 12 ;
 
Parameters (R input):
par1 = multiplicative ; 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