Home » date » 2010 » Dec » 27 »

Classical Decomposition

*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: Mon, 27 Dec 2010 10:06:19 +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/27/t1293444315cnk9bjbavme3v4u.htm/, Retrieved Mon, 27 Dec 2010 11:05:19 +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/27/t1293444315cnk9bjbavme3v4u.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:
prijsverandering in Nederland
 
IsPrivate?
No (this computation is public)
 
User-defined keywords:
 
Dataseries X:
» Textbox « » Textfile « » CSV «
13.7 13.7 13.7 1.3 1.3 1.3 -7.4 -7.4 -7.4 -12.9 -12.9 -12.9 -9.6 -9.6 -9.6 -11.1 -11.1 -11.1 -8.3 -8.3 -8.3 -2.7 -2.7 -2.7 5.1 5.1 5.1 4.6 4.6 4.6 5.6 5.6 5.6 5.1 5.1 5.1 0.8 0.8 0.8 6 6 6 9.3 9.3 9.3 8.7 8.7 8.7 11 11 11 8.5 8.5 8.5 4.4 4.4 4.4 2.5 2.5 2.5 0.3 0.3 0.3 -3 -3 -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'George Udny Yule' @ 72.249.76.132


Classical Decomposition by Moving Averages
tObservationsFitTrendSeasonalRandom
113.7NANA3.57228193625257NA
213.7NANA0.951193791268256NA
313.7NANA0.698612144839178NA
41.3NANA0.735412071575998NA
51.3NANA0.72127807155013NA
61.3NANA0.722252280763126NA
7-7.4-1.60978773266566-2.295833333333330.7011779597817754.59687935858865
8-7.4-3.16020078357764-4.23750.7457700964195032.34162336724140
9-7.4-5.09326574430955-6.179166666666670.8242641797938581.45289886125962
10-12.9-4.53864768800151-7.666666666666670.5919975245219362.84225630337045
11-12.9-6.05557909466641-8.70.6960435740995882.13026694859984
12-12.9-10.1199059929051-9.733333333333331.039716369134091.27471539844777
13-9.6-36.7498504191983-10.28753.572281936252570.261225553042929
14-9.6-9.8567456620173-10.36250.9511937912682560.973952289039306
15-9.6-7.29176426175891-10.43750.6986121448391781.31655380719676
16-11.1-7.39089131933878-10.050.7354120715759981.50184862967151
17-11.1-6.63575825826119-9.20.721278071550131.67275533073874
18-11.1-6.0308065443721-8.350.7222522807631261.84054983663146
19-8.3-5.12736383090423-7.31250.7011779597817751.61876556330434
20-8.3-4.53987546195372-6.08750.7457700964195031.82824398368587
21-8.3-4.00798457424764-4.86250.8242641797938582.07086625366018
22-2.7-2.12872443192679-3.595833333333330.5919975245219361.26836520477013
23-2.7-1.59219967575281-2.28750.6960435740995881.69576720879774
24-2.7-1.01805561144380-0.9791666666666671.039716369134092.65211445195110
255.10.9079549921308580.2541666666666663.572281936252575.61701851325354
265.11.343561230166411.41250.9511937912682563.79588208225413
275.11.796015389024052.570833333333330.6986121448391782.83961932128617
284.62.555556948726593.4750.7354120715759981.79999901872354
294.62.975272045144284.1250.721278071550131.54607710831260
304.63.448754640643924.7750.7222522807631261.33381480543398
315.63.450379877092824.920833333333330.7011779597817751.62300969733176
325.63.402576064913984.56250.7457700964195031.64581184760129
335.63.465343989216684.204166666666670.8242641797938581.61600118701804
345.12.417323225131244.083333333333330.5919975245219362.10977164616582
355.12.923383011218274.20.6960435740995881.74455416222545
365.14.488108993428824.316666666666671.039716369134091.13633603984820
370.816.17946026961064.529166666666673.572281936252570.0494454071192113
380.84.601399965260194.83750.9511937912682560.173860130838412
390.83.594941661984935.145833333333330.6986121448391780.222534904657753
4064.007995790089195.450.7354120715759981.49700756044619
4164.147348911413245.750.721278071550131.44670731307134
4264.369626298616916.050.7222522807631261.37311513387292
439.34.645303983554266.6250.7011779597817752.00202183386162
449.35.574631470735787.4750.7457700964195031.66827171425065
459.36.861999296783878.3250.8242641797938581.35529014180441
468.75.241644748371318.854166666666670.5919975245219361.65978436495592
478.76.307894890277519.06250.6960435740995881.37922399648883
488.79.63903717218069.270833333333331.039716369134090.902579774783857
491132.76080225704969.170833333333333.572281936252570.335767113201051
50118.334835595988098.76250.9511937912682561.31976208448488
51115.836322293343968.354166666666660.6986121448391781.88474855347604
528.55.803626931520587.891666666666670.7354120715759981.46460137777549
538.55.31942577768227.3750.721278071550131.59791683449405
548.54.953446892233776.858333333333330.7222522807631261.71597681067837
554.44.315166027490346.154166666666670.7011779597817751.01965949211901
564.43.924615132407635.26250.7457700964195031.12112904107892
574.43.602721352515664.370833333333330.8242641797938581.22129900413409
582.52.039924803248503.445833333333330.5919975245219361.22553537072486
592.51.731408390572722.48750.6960435740995881.44391121910472
602.51.589899614467541.529166666666671.039716369134091.57242632003358
610.3NANANANA
620.3NANANANA
630.3NANANANA
64-3NANANANA
65-3NANANANA
66-3NANANANA
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Dec/27/t1293444315cnk9bjbavme3v4u/1w9hk1293444376.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/27/t1293444315cnk9bjbavme3v4u/1w9hk1293444376.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/27/t1293444315cnk9bjbavme3v4u/2w9hk1293444376.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/27/t1293444315cnk9bjbavme3v4u/2w9hk1293444376.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/27/t1293444315cnk9bjbavme3v4u/3o1z51293444376.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/27/t1293444315cnk9bjbavme3v4u/3o1z51293444376.ps (open in new window)


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