Home » date » 2010 » Dec » 14 »

*Unverified author*
R Software Module: /rwasp_decompose.wasp (opens new window with default values)
Title produced by software: Classical Decomposition
Date of computation: Tue, 14 Dec 2010 14:18:13 +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/14/t129233618472jvbkmh92k3uxo.htm/, Retrieved Tue, 14 Dec 2010 15:16:29 +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/14/t129233618472jvbkmh92k3uxo.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:
KDGP2W92
 
Dataseries X:
» Textbox « » Textfile « » CSV «
47 19 52 136 80 42 54 66 81 63 137 72 107 58 36 52 79 77 54 84 48 96 83 66 61 53 30 74 69 59 42 65 70 100 63 105 82 81 75 102 121 98 76 77 63 37 35 23 40 29 37 51 20 28 13 22 25 13 16 13 16 17 9 17 25 14 8 7 10 7 10 3
 
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'Gwilym Jenkins' @ 72.249.127.135


Classical Decomposition by Moving Averages
tObservationsFitTrendSeasonalRandom
147NANA1.06203925271391NA
219NANA0.88835534534093NA
352NANA0.72148677507893NA
4136NANA1.21255999585695NA
580NANA1.26161693313592NA
642NANA1.09886963250546NA
75454.892465834136473.250.7493851991008380.983741560511545
86679.773977658657677.3751.031004557785560.82733745937059
98176.560977943432178.33333333333330.97737418651191.05798021623819
106373.105889048771274.16666666666670.985697380432870.86176368032363
1113778.18260490780870.6251.107010334977811.75230794831598
127265.168920955849472.04166666666670.9046004065589271.10482111632289
1310778.059885074472373.51.062039252713911.37074247416477
145865.96038439156474.250.888355345340930.879315676144208
153653.119463815186273.6250.721486775078930.677717684147783
165289.274729694968173.6251.212559995856950.582471659983429
177991.782631885637972.751.261616933135920.860729294605921
187777.195591683508370.251.098869632505460.997466284288484
195451.020642305448768.08333333333330.7493851991008381.05839514282699
208468.003342290605865.95833333333331.031004557785561.23523340427937
214864.018009216529465.50.97737418651190.74978901386403
229665.220310005308266.16666666666670.985697380432871.47193412592161
238373.800688998520966.66666666666671.107010334977811.12465074684687
246659.251326629609765.50.9046004065589271.11389911001618
256168.236021986868664.251.062039252713910.893955981369179
265355.929371950422762.95833333333330.888355345340930.94762372885182
273045.513790727895863.08333333333330.721486775078930.659140878406612
287477.805933067487764.16666666666671.212559995856950.951084282169247
296980.112675254130663.51.261616933135920.86128692845571
305970.648160123163364.29166666666671.098869632505460.835124366963603
314250.052686423276866.79166666666670.7493851991008380.839115799795874
326570.967480394239268.83333333333331.031004557785560.915912466370672
337070.248769655542871.8750.97737418651190.99645873291785
3410073.845162084095874.91666666666670.985697380432871.35418485351984
356386.623558712013978.251.107010334977810.72728482801599
3610574.214925021438682.04166666666670.9046004065589271.41480975652362
378290.361839751741785.08333333333331.062039252713910.907462710202505
388177.2869150446609870.888355345340931.04804286667664
397562.91965917667587.20833333333330.721486775078931.19199628512615
40102102.20870298410984.29166666666671.212559995856950.997958070320672
41121101.56016311744180.51.261616933135921.19141202894760
429883.422519601039275.91666666666671.098869632505461.17474274894449
437653.019002836384370.750.7493851991008381.43344830974160
447768.905471278668166.83333333333331.031004557785561.11747294621346
456361.656021599125763.08333333333330.97737418651191.02179800716972
463758.525781963201759.3750.985697380432870.632200010984286
473558.717673184448253.04166666666671.107010334977810.596072666061809
482341.536235334497445.91666666666670.9046004065589270.553733380379267
494042.879834828324140.3751.062039252713910.932839414147608
502931.499599953547135.45833333333330.888355345340930.920646612743231
513722.786957312909531.58333333333330.721486775078931.62373587188134
525135.1642398798516291.212559995856951.45033705191
532034.326494055739727.20833333333331.261616933135920.582640335116188
542828.5706104451419261.098869632505460.98002806253519
551318.422386144562324.58333333333330.7493851991008380.705663202257716
562223.799021875550023.08333333333331.031004557785560.924407738899631
572520.932097161129921.41666666666670.97737418651191.19433804494392
581318.563967331485718.83333333333330.985697380432870.700281344384351
591619.511057153984017.6251.107010334977810.82004782589307
601315.604357013141517.250.9046004065589270.833100651891764
611617.479396034249716.45833333333331.062039252713910.915363435249652
621713.880552270952015.6250.888355345340931.22473513071782
63910.371372391759614.3750.721486775078930.867773295571836
641716.369559944068813.51.212559995856951.03851295075037
652516.4010201307669131.261616933135921.52429542800830
661413.552725467567312.33333333333331.098869632505461.03300255240196
678NANA0.749385199100838NA
687NANA1.03100455778556NA
6910NANA0.9773741865119NA
707NANA0.98569738043287NA
7110NANA1.10701033497781NA
723NANA0.904600406558927NA
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Dec/14/t129233618472jvbkmh92k3uxo/11fsl1292336290.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/14/t129233618472jvbkmh92k3uxo/11fsl1292336290.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/14/t129233618472jvbkmh92k3uxo/21fsl1292336290.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/14/t129233618472jvbkmh92k3uxo/21fsl1292336290.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/14/t129233618472jvbkmh92k3uxo/3cor61292336290.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/14/t129233618472jvbkmh92k3uxo/3cor61292336290.ps (open in new window)


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