Home » date » 2010 » Dec » 14 »

9.2

*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 21:25:25 +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/t1292361807ubwy8nck2cx4d3u.htm/, Retrieved Tue, 14 Dec 2010 22:23:27 +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/t1292361807ubwy8nck2cx4d3u.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 «
89,3 88,1 93,6 79,7 83,8 62,3 62,3 77,6 80,3 97 94 75,1 74 77,6 75,1 85 75,4 63,2 64,7 77 82,6 97,6 99 75,3 71,6 76,8 83,9 79,7 77,5 73,1 65,6 85,2 98,3 98 100,6 84,1 76,7 82,4 95,5 79,9 82,4 83,6 73,1 91,1 118,6 102,9 111,8 93,9 91,6 92 91,1 97,5 94,7 96,7 78,7 103,5 113,8 106,1 120,3 114,2 106,3 98,8 113,1 97,7 116,3 107,2 94,5 123,5 126,6 126,5 141,4 124,3 124,9 108,9 126,7 107,7 121,8 118,3 122,8 149,5 147 139,3 162,1 142,2 141,4 124,7 114 126,6 121,9 125,1 122,1 135,9 148,4 137,5 145,3 139,9 128,2 115,4 124,7 111,5 121,1 122,5 127,4 143,7 157,8 148,8 162,9 153,9
 
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'Sir Ronald Aylmer Fisher' @ 193.190.124.24


Classical Decomposition by Moving Averages
tObservationsFitTrendSeasonalRandom
189.3NANA0.970572002616154NA
288.1NANA0.934106720975305NA
393.6NANA0.984777066169892NA
479.7NANA0.937098356954485NA
583.8NANA0.952258735620644NA
662.3NANA0.914458967391912NA
762.367.665925131862281.28750.8324271890741160.920699744791703
877.682.424029446634980.21251.027570882925170.941473020925794
980.388.491082716716879.00416666666671.120081211540110.907436066265133
109787.735707032558578.45416666666671.118305257199751.10559318754910
119493.152523190718878.3251.189307669208031.00909773326855
1275.179.497541294560378.01251.019035940324440.944683304377097
137475.850202004452578.150.9705720026161540.975607157851157
1477.673.070498248293278.2250.9341067209753051.06198810546379
1575.177.103941043326878.29583333333330.9847770661698920.974009875290282
168573.484129491180978.41666666666670.9370983569544851.15671234848337
1775.474.895149556563678.650.9522587356206441.00674076287217
1863.272.120330561642178.86666666666670.9144589673919120.876313232452286
1964.765.574451819313578.7750.8324271890741160.986664748311995
207780.809886851373378.64166666666671.027570882925170.952853703923871
2182.688.458413681380278.9751.120081211540110.933772114629122
2297.688.481243870691779.12083333333331.118305257199751.10305863401553
239993.94043952156978.98751.189307669208031.05385923787667
2475.381.000619306538979.48751.019035940324440.929622521959178
2571.677.585099459128879.93750.9705720026161540.922857616979898
2676.875.024338139666680.31666666666660.9341067209753051.02366781106456
2783.980.074685192939381.31250.9847770661698921.04777183697749
2879.776.826446964318681.98333333333330.9370983569544851.03740317493813
2977.578.148700236600882.06666666666670.9522587356206440.991699155140945
3073.175.442864809832782.50.9144589673919120.968945177045724
3165.669.157357178953383.07916666666670.8324271890741160.948561406565201
3285.285.827857996324583.5251.027570882925170.992684682910863
3398.394.357508062158184.24166666666671.120081211540111.04178249318798
349894.757732126725284.73333333333331.118305257199751.03421639374968
35100.6101.02673105060084.94583333333331.189307669208030.995776058017887
3684.187.21673854251885.58751.019035940324440.96426444516727
3776.783.796760275872286.33750.9705720026161540.915309849062081
3882.481.169981941416686.89583333333330.9341067209753051.01515360764120
3995.586.648072109623487.98750.9847770661698921.10215954809909
4079.983.43689495733589.03750.9370983569544850.957609940313053
4182.485.425544074635389.70833333333330.9522587356206440.964582677144065
4283.682.834741462917390.58333333333330.9144589673919121.00923837659861
4373.176.260735859052591.61250.8324271890741160.95855356202051
4491.195.187316121634692.63333333333331.027570882925170.957060286095138
45118.6103.99954049149992.851.120081211540111.14038965402635
46102.9104.44971102245693.41.118305257199750.985163089420868
47111.8112.56301544191894.64583333333331.189307669208030.993221437441751
4893.997.525985472133695.70416666666671.019035940324440.962820314456914
4991.693.644022052415396.48333333333330.9705720026161540.978172423528848
509290.826310169498997.23333333333330.9341067209753051.01292235507873
5191.196.06500280487397.550.9847770661698920.948316216521038
5297.591.35147149711397.48333333333330.9370983569544851.06730628858104
5394.793.293581877700897.97083333333330.9522587356206441.01507518624532
5496.790.687657845395499.17083333333330.9144589673919121.06629724813110
5578.783.7664543472041100.6291666666670.8324271890741160.939516905822418
56103.5104.324133888978101.5251.027570882925170.99210025659207
57113.8115.060342455458102.7251.120081211540110.989046248007251
58106.1115.912339908754103.651.118305257199750.915346891310467
59120.3124.352027712943104.5583333333331.189307669208030.96741486417659
60114.2107.911660097273105.8958333333331.019035940324441.05827303460125
61106.3103.843116179907106.9916666666670.9705720026161541.02365957331092
6298.8101.335010780471108.4833333333330.9341067209753050.97498386035639
63113.1108.177760718763109.850.9847770661698921.04550139740860
6497.7104.236573905237111.2333333333330.9370983569544850.937290975131438
65116.3107.569527422547112.96250.9522587356206441.08116120602779
66107.2104.488367761618114.26250.9144589673919121.02595152260937
6794.596.110655871849115.4583333333330.8324271890741160.983241651435647
68123.5119.870425038566116.6541666666671.027570882925171.03027915317949
69126.6131.768220527598117.6416666666671.120081211540110.960777943976899
70126.5132.65896113532118.6251.118305257199750.9535729732646
71141.4141.849716796166119.2708333333331.189307669208030.996829624998039
72124.3122.246098991171119.96251.019035940324441.01680136238112
73124.9118.025599568135121.6041666666670.9705720026161541.05824499478942
74108.9115.704685838141123.8666666666670.9341067209753050.941189193947943
75126.7123.884954924172125.80.9847770661698921.02272305848237
76107.7119.183292698661127.1833333333330.9370983569544850.903650147276135
77121.8122.440634677156128.5791666666670.9522587356206440.994767793560976
78118.3119.051126817335130.18750.9144589673919120.993690720638982
79122.8109.564760315259131.6208333333330.8324271890741161.12079832645695
80149.5136.632675066283132.9666666666671.027570882925171.09417458106178
81147149.078142250941133.0958333333331.120081211540110.986060047304303
82139.3149.130665652825133.3541666666671.118305257199750.93408018659482
83162.1159.540668375635134.1458333333331.189307669208031.01604187603338
84142.2136.992398244282134.4333333333331.019035940324441.03801380092954
85141.4130.723916602363134.68750.9705720026161541.08166893767505
86124.7125.255927060114134.0916666666670.9341067209753050.995561670627795
87114131.549803089195133.5833333333330.9847770661698920.86659194710238
88126.6125.165103877221133.5666666666670.9370983569544851.01146402693986
89121.9126.452024600958132.7916666666670.9522587356206440.964001963469366
90125.1120.704773450035131.9958333333330.9144589673919121.03641303010924
91122.1109.339311284885131.350.8324271890741161.11670723516693
92135.9134.008087769478130.41251.027570882925171.01411789588235
93148.4146.137929070648130.4708333333331.120081211540111.01547901317432
94137.5145.701196197412130.28751.118305257199750.943712224666295
95145.3154.164006621091129.6251.189307669208030.94250274875849
96139.9131.948170339676129.4833333333331.019035940324441.06026479669899
97128.2125.782087489043129.5958333333330.9705720026161541.01922302737397
98115.4121.566205512261130.1416666666670.9341067209753050.949276976390949
99124.7128.866285583882130.8583333333330.9847770661698920.967669700690101
100111.5123.435376493342131.7208333333330.9370983569544850.903306678908327
101121.1126.578992432374132.9250.9522587356206440.95671483611073
102122.5122.758495880969134.2416666666670.9144589673919120.997894272986043
103127.4NANA0.832427189074116NA
104143.7NANA1.02757088292517NA
105157.8NANA1.12008121154011NA
106148.8NANA1.11830525719975NA
107162.9NANA1.18930766920803NA
108153.9NANA1.01903594032444NA
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Dec/14/t1292361807ubwy8nck2cx4d3u/1nc851292361921.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/14/t1292361807ubwy8nck2cx4d3u/1nc851292361921.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/14/t1292361807ubwy8nck2cx4d3u/2nc851292361921.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/14/t1292361807ubwy8nck2cx4d3u/2nc851292361921.ps (open in new window)


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


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