Home » date » 2010 » Dec » 28 »

*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, 28 Dec 2010 12:20:45 +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/Dec/28/t1293538754vsb3v8dji4p111f.htm/, Retrieved Tue, 28 Dec 2010 13:19:15 +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/2010/Dec/28/t1293538754vsb3v8dji4p111f.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:
 
Dataseries X:
» Textbox « » Textfile « » CSV «
4,031636 3,702076 3,056167 3,280707 2,984728 3,693712 3,226317 2,190349 2,599515 3,080288 2,929672 2,922548 3,234943 2,983081 3,284389 3,806511 3,784579 2,645654 3,092081 3,204859 3,107225 3,466909 2,984404 3,218072 2,827310 3,182049 2,236319 2,033218 1,644804 1,627971 1,677559 2,330828 2,493615 2,257172 2,655517 2,298655 2,600402 3,045230 2,790583 3,227052 2,967479 2,938817 3,277961 3,423985 3,072646 2,754253 2,910431 3,174369 3,068387 3,089543 2,906654 2,931161 3,025660 2,939551 2,691019 3,198120 3,076390 2,863873 3,013802 3,053364 2,864753 3,057062 2,959365 3,252258 3,602988 3,497704 3,296867 3,602417 3,300100 3,401930 3,502591 3,402348 3,498551 3,199823 2,700064 2,801034 2,898628 2,800854 2,399942 2,402724 2,202331 2,102594 1,798293 1,202484 1,400201 1,200832 1,298083 1,099742 1,001377 0,836174
 
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'RServer@AstonUniversity' @ vre.aston.ac.uk


Classical Decomposition by Moving Averages
tObservationsFitTrendSeasonalRandom
14.031636NANA0.046548175347222NA
23.702076NANA0.127885730902778NA
33.056167NANA-0.150733206597223NA
43.280707NANA0.054457890625NA
52.984728NANA0.047921564236111NA
63.693712NANA-0.177874581597222NA
73.2263172.952571946180563.10828070833333-0.1557087621527780.273745053819444
82.1903493.202453605902783.045127041666670.157326564236111-1.01210460590278
92.5995153.056404251736113.024678166666670.0317260850694447-0.456889251736111
103.0802883.052816800347223.05609591666667-0.003279116319444550.0274711996527781
112.9296723.1492283906253.111331541666670.0378968489583335-0.219556390624999
122.9225483.0848223906253.10098958333333-0.0161671927083335-0.162274390624999
133.2349433.098275508680563.051727333333330.0465481753472220.136667491319444
142.9830813.216291147569443.088405416666670.127885730902778-0.233210147569444
153.2843893.001098043402783.15183125-0.1507332065972230.283290956597223
163.8065113.243552932291673.189095041666670.0544578906250.562958067708333
173.7845793.255406314236113.207484750.0479215642361110.529172685763889
182.6456543.044204168402783.22207875-0.177874581597222-0.398550168402778
193.0920813.061698779513893.21740754166667-0.1557087621527780.0303822204861115
203.2048593.366039730902783.208713166666670.157326564236111-0.161180730902777
213.1072253.205060001736113.173333916666670.0317260850694447-0.0978350017361107
223.4669093.052498008680563.055777125-0.003279116319444550.414410991319444
232.9844042.930629473958332.8927326250.03789684895833350.0537745260416673
243.2180722.745004682291672.761171875-0.01616719270833350.473067317708333
252.827312.706378175347222.659830.0465481753472220.120931824652778
263.1820492.692359355902782.5644736250.1278857309027780.489689644097223
272.2363192.351755376736112.50248858333333-0.150733206597223-0.115436376736111
282.0332182.480973682291672.426515791666670.054457890625-0.447755682291666
291.6448042.410328022569442.362406458333330.047921564236111-0.765524022569445
301.6279712.132519210069442.31039379166667-0.177874581597222-0.504548210069445
311.6775592.106921487847222.26263025-0.155708762152778-0.429362487847222
322.3308282.404801522569442.247474958333330.157326564236111-0.0739735225694447
332.4936152.296594585069442.26486850.03172608506944470.197020414930555
342.2571722.334426800347222.33770591666667-0.00327911631944455-0.0772548003472222
352.6555172.480457307291672.442560458333330.03789684895833350.175059692708334
362.2986552.536123307291672.5522905-0.0161671927083335-0.237468307291666
372.6004022.720140675347222.67359250.046548175347222-0.119738675347222
383.045232.913709855902782.7858241250.1278857309027780.131520144097223
392.7905832.704765418402782.855498625-0.1507332065972230.0858175815972224
403.2270522.9547945156252.9003366250.0544578906250.272257484375
412.9674792.979591314236112.931669750.047921564236111-0.0121123142361101
422.9388172.800904668402782.97877925-0.1778745815972220.137912331597222
433.2779612.879057946180563.03476670833333-0.1557087621527780.398903053819445
443.4239853.213439022569443.056112458333330.1573265642361110.210545977430556
453.0726463.094521210069443.0627951250.0317260850694447-0.0218752100694437
462.7542533.052023508680563.055302625-0.00327911631944455-0.297770508680556
472.9104313.0832948906253.045398041666670.0378968489583335-0.172863890625
483.1743693.0316856406253.04785283333333-0.01616719270833350.142683359374999
493.0683873.069975675347223.02342750.046548175347222-0.00158867534722207
503.0895433.117446272569442.989560541666670.127885730902778-0.0279032725694446
512.9066542.829572293402782.9803055-0.1507332065972230.0770817065972227
522.9311613.0394868906252.9850290.054457890625-0.108325890625
533.025663.041825189236112.9939036250.047921564236111-0.0161651892361108
542.9395512.815294293402782.993168875-0.1778745815972220.124256706597222
552.6910192.823933487847222.97964225-0.155708762152778-0.132914487847223
563.198123.127130689236112.9698041250.1573265642361110.0709893107638893
573.076393.002373126736112.970647041666670.03172608506944470.0740168732638886
582.8638732.982943258680562.986222375-0.00327911631944455-0.119070258680555
593.0138023.061553598958333.023656750.0378968489583335-0.0477515989583326
603.0533643.0548012656253.07096845833333-0.0161671927083335-0.00143726562499902
612.8647533.166016675347223.11946850.046548175347222-0.301263675347222
623.0570623.289443605902783.1615578750.127885730902778-0.232381605902777
632.9593653.036991626736113.18772483333333-0.150733206597223-0.0776266267361105
643.2522583.2739230156253.2194651250.054457890625-0.0216650156249996
653.6029883.310171939236113.2622503750.0479215642361110.292816060763889
663.4977043.119283001736113.29715758333333-0.1778745815972220.37842099826389
673.2968673.182398071180563.33810683333333-0.1557087621527780.114468928819445
683.6024173.527790022569443.370463458333330.1573265642361110.0746269774305559
693.30013.397333710069443.3656076250.0317260850694447-0.0972337100694438
703.401933.332723300347223.33600241666667-0.003279116319444550.0692066996527783
713.5025913.325749932291673.287853083333330.03789684895833350.176841067708334
723.4023483.2133021406253.22946933333333-0.01616719270833350.189045859375
733.4985513.209610217013893.163062041666670.0465481753472220.288940782986111
743.1998233.203588689236113.075702958333330.127885730902778-0.00376568923611087
752.7000642.829242168402782.979975375-0.150733206597223-0.129178168402778
762.8010342.9345538906252.8800960.054457890625-0.133519890625
772.8986282.802866147569442.754944583333330.0479215642361110.095761852430556
782.8008542.414396585069442.59227116666667-0.1778745815972220.386457414930556
792.3999422.257470154513892.41317891666667-0.1557087621527780.142471845486111
802.4027242.399782939236112.2424563750.1573265642361110.00294106076388889
812.2023312.132475293402782.100749208333330.03172608506944470.0698557065972221
822.1025941.968167050347221.97144616666667-0.003279116319444550.134426949652778
831.7982931.859403723958331.8215068750.0378968489583335-0.0611107239583335
841.2024841.6444258906251.66059308333333-0.0161671927083335-0.441941890624999
851.400201NANANANA
861.200832NANANANA
871.298083NANANANA
881.099742NANANANA
891.001377NANANANA
900.836174NANANANA
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Dec/28/t1293538754vsb3v8dji4p111f/1ud5c1293538841.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/28/t1293538754vsb3v8dji4p111f/1ud5c1293538841.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/28/t1293538754vsb3v8dji4p111f/2ud5c1293538841.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/28/t1293538754vsb3v8dji4p111f/2ud5c1293538841.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/28/t1293538754vsb3v8dji4p111f/3mnnx1293538841.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/28/t1293538754vsb3v8dji4p111f/3mnnx1293538841.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/28/t1293538754vsb3v8dji4p111f/4mnnx1293538841.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/28/t1293538754vsb3v8dji4p111f/4mnnx1293538841.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