Home » date » 2010 » Jan » 12 »

*Unverified author*
R Software Module: /rwasp_decompose.wasp (opens new window with default values)
Title produced by software: Classical Decomposition
Date of computation: Tue, 12 Jan 2010 02:35:07 -0700
 
Cite this page as follows:
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL http://www.freestatistics.org/blog/date/2010/Jan/12/t1263289052ftgjyu1opa5ci7n.htm/, Retrieved Tue, 12 Jan 2010 10:37:37 +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/Jan/12/t1263289052ftgjyu1opa5ci7n.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:
KDGP2W52
 
Dataseries X:
» Textbox « » Textfile « » CSV «
2.25 2.06 1.99 2.25 2.26 2.36 2.3 2.19 2.31 2.21 2.21 2.26 2.18 2.21 2.33 2.12 2.08 1.97 2.09 2.11 2.24 2.45 2.68 2.73 2.76 2.83 3.16 3.22 3.22 3.34 3.35 3.42 3.58 3.71 3.68 3.83 3.94 3.88 4.03 4.15 4.32 4.4 4.37 4.14 4.11 4.16 3.98 4.13 3.76 3.66 3.85 4.03 4.31 4.58 4.46 4.41 3.84 2.84 2.66 2.17 1.43 1.47 1.29 1.23 1.09 0.94 0.76 0.67
 
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
12.25NANA-0.130086805555555NA
22.06NANA-0.190711805555556NA
31.99NANA-0.0322743055555553NA
42.25NANA-0.0172743055555555NA
52.26NANA0.0739756944444445NA
62.36NANA0.160225694444444NA
72.32.381892361111112.217916666666670.163975694444444-0.081892361111111
82.192.353246527777782.221250.131996527777778-0.163246527777777
92.312.314704861111112.241666666666670.0730381944444445-0.00470486111111068
102.212.191059027777782.25041666666667-0.0593576388888890.0189409722222225
112.212.157725694444442.2375-0.07977430555555570.0522743055555557
122.262.120017361111112.21375-0.0937326388888890.139982638888889
132.182.058663194444442.18875-0.1300868055555550.121336805555556
142.211.985954861111112.17666666666667-0.1907118055555560.224045138888889
152.332.138142361111112.17041666666667-0.03227430555555530.191857638888889
162.122.160225694444442.1775-0.0172743055555555-0.0402256944444441
172.082.281059027777782.207083333333330.0739756944444445-0.201059027777778
181.972.406475694444442.246250.160225694444444-0.436475694444444
192.092.453975694444442.290.163975694444444-0.363975694444445
202.112.471996527777782.340.131996527777778-0.361996527777778
212.242.473454861111112.400416666666670.0730381944444445-0.233454861111111
222.452.421475694444442.48083333333333-0.0593576388888890.0285243055555560
232.682.494392361111112.57416666666667-0.07977430555555570.185607638888889
242.732.585017361111112.67875-0.0937326388888890.144982638888889
252.762.658246527777782.78833333333333-0.1300868055555550.101753472222223
262.832.704704861111112.89541666666667-0.1907118055555560.125295138888889
273.162.973559027777783.00583333333333-0.03227430555555530.186440972222222
283.223.096892361111113.11416666666667-0.01727430555555550.123107638888889
293.223.282309027777783.208333333333330.0739756944444445-0.0623090277777774
303.343.456059027777783.295833333333330.160225694444444-0.116059027777778
313.353.554809027777783.390833333333330.163975694444444-0.204809027777777
323.423.615746527777783.483750.131996527777778-0.195746527777777
333.583.636788194444453.563750.0730381944444445-0.0567881944444451
343.713.579392361111113.63875-0.0593576388888890.130607638888889
353.683.643559027777783.72333333333333-0.07977430555555570.0364409722222221
363.833.719600694444443.81333333333333-0.0937326388888890.110399305555556
373.943.769913194444443.9-0.1300868055555550.170086805555556
383.883.781788194444443.9725-0.1907118055555560.098211805555556
394.033.992309027777784.02458333333333-0.03227430555555530.0376909722222223
404.154.048142361111114.06541666666667-0.01727430555555550.101857638888889
414.324.170642361111114.096666666666670.07397569444444450.149357638888890
424.44.281892361111114.121666666666670.1602256944444440.118107638888890
434.374.290642361111114.126666666666670.1639756944444440.0793576388888892
444.144.241996527777784.110.131996527777778-0.101996527777779
454.114.166371527777784.093333333333330.0730381944444445-0.0563715277777765
464.164.021475694444444.08083333333333-0.0593576388888890.138524305555556
473.983.995642361111114.07541666666667-0.0797743055555557-0.0156423611111105
484.133.988767361111114.0825-0.0937326388888890.141232638888889
493.763.963663194444444.09375-0.130086805555555-0.203663194444444
503.663.918038194444454.10875-0.190711805555556-0.258038194444445
513.854.076475694444444.10875-0.0322743055555553-0.226475694444444
524.034.025225694444444.0425-0.01727430555555550.00477430555555536
534.314.006475694444453.93250.07397569444444450.303524305555555
544.583.956059027777783.795833333333330.1602256944444440.623940972222222
554.463.781059027777783.617083333333330.1639756944444440.678940972222223
564.413.560746527777783.428750.1319965277777780.849253472222223
573.843.303871527777783.230833333333330.07303819444444450.536128472222222
582.842.948142361111113.0075-0.059357638888889-0.108142361111111
592.662.676892361111112.75666666666667-0.0797743055555557-0.0168923611111111
602.172.377100694444442.47083333333333-0.093732638888889-0.207100694444444
611.43NA2.165NANA
621.47NA1.855NANA
631.29NANANANA
641.23NANANANA
651.09NANANANA
660.94NANANANA
670.76NANANANA
680.67NANANANA
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Jan/12/t1263289052ftgjyu1opa5ci7n/1y1yv1263288905.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Jan/12/t1263289052ftgjyu1opa5ci7n/1y1yv1263288905.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Jan/12/t1263289052ftgjyu1opa5ci7n/22eie1263288905.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Jan/12/t1263289052ftgjyu1opa5ci7n/22eie1263288905.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Jan/12/t1263289052ftgjyu1opa5ci7n/35z3t1263288905.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Jan/12/t1263289052ftgjyu1opa5ci7n/35z3t1263288905.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Jan/12/t1263289052ftgjyu1opa5ci7n/4u4wp1263288905.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Jan/12/t1263289052ftgjyu1opa5ci7n/4u4wp1263288905.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