Home » date » 2010 » Aug » 17 »

TIJDREEKS B - STAP 24

*Unverified author*
R Software Module: /rwasp_decompose.wasp (opens new window with default values)
Title produced by software: Classical Decomposition
Date of computation: Tue, 17 Aug 2010 19:39:43 +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/Aug/17/t128207396234tfnf4obmo3p63.htm/, Retrieved Tue, 17 Aug 2010 21:39:22 +0200
 
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/Aug/17/t128207396234tfnf4obmo3p63.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:
Schrauwen Nathalie
 
Dataseries X:
» Textbox « » Textfile « » CSV «
162 161 160 158 156 155 156 158 159 159 160 162 168 177 174 169 169 160 168 172 173 175 170 177 187 201 188 179 176 170 179 183 174 177 170 166 171 178 165 162 159 149 153 156 149 150 139 131 141 150 128 124 120 113 120 121 115 119 106 98 106 116 93 94 90 93 100 99 90 91 83 83 92 104 71 69 67 75 86 81 88 87 77 70
 
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
1162NANA4.7181712962963NA
2161NANA15.9056712962963NA
3160NANA-0.899884259259263NA
4158NANA-3.57349537037038NA
5156NANA-5.16377314814815NA
6155NANA-7.44849537037037NA
7156159.051504629630159.083333333333-0.0318287037037035-3.05150462962965
8158163.0167824074071603.01678240740741-5.01678240740745
9159160.447337962963161.25-0.802662037037035-1.44733796296293
10159164.558449074074162.2916666666672.2667824074074-5.55844907407408
11160159.627893518519163.291666666667-3.663773148148140.372106481481495
12162159.718171296296164.041666666667-4.323495370370372.28182870370370
13168169.468171296296164.754.7181712962963-1.46817129629628
14177181.739004629630165.83333333333315.9056712962963-4.73900462962965
15174166.100115740741167-0.8998842592592637.89988425925927
16169164.676504629630168.25-3.573495370370384.32349537037038
17169164.169560185185169.333333333333-5.163773148148154.83043981481487
18160162.926504629630170.375-7.44849537037037-2.92650462962962
19168171.759837962963171.791666666667-0.0318287037037035-3.75983796296296
20172176.600115740741173.5833333333333.01678240740741-4.60011574074076
21173174.364004629630175.166666666667-0.802662037037035-1.36400462962965
22175178.433449074074176.1666666666672.2667824074074-3.43344907407405
23170173.211226851852176.875-3.66377314814814-3.21122685185185
24177173.259837962963177.583333333333-4.323495370370373.74016203703704
25187183.176504629630178.4583333333334.71817129629633.82349537037035
26201195.280671296296179.37515.90567129629635.71932870370372
27188178.975115740741179.875-0.8998842592592639.02488425925924
28179176.426504629630180-3.573495370370382.57349537037038
29176174.919560185185180.083333333333-5.163773148148151.08043981481478
30170172.176504629630179.625-7.44849537037037-2.17650462962965
31179178.468171296296178.5-0.03182870370370350.531828703703695
32183179.891782407407176.8753.016782407407413.10821759259261
33174174.155671296296174.958333333333-0.802662037037035-0.155671296296276
34177175.558449074074173.2916666666672.26678240740741.44155092592595
35170168.211226851852171.875-3.663773148148141.78877314814818
36166165.968171296296170.291666666667-4.323495370370370.0318287037036953
37171173.051504629630168.3333333333334.7181712962963-2.05150462962965
38178182.030671296296166.12515.9056712962963-4.03067129629628
39165163.058449074074163.958333333333-0.8998842592592631.94155092592595
40162158.218171296296161.791666666667-3.573495370370383.78182870370372
41159154.211226851852159.375-5.163773148148154.78877314814815
42149149.176504629630156.625-7.44849537037037-0.176504629629619
43153153.884837962963153.916666666667-0.0318287037037035-0.884837962962962
44156154.516782407407151.53.016782407407411.48321759259258
45149147.989004629630148.791666666667-0.8026620370370351.01099537037035
46150147.933449074074145.6666666666672.26678240740742.06655092592592
47139138.794560185185142.458333333333-3.663773148148140.205439814814810
48131135.009837962963139.333333333333-4.32349537037037-4.00983796296299
49141141.176504629630136.4583333333334.7181712962963-0.176504629629619
50150149.530671296296133.62515.90567129629630.469328703703695
51128129.850115740741130.75-0.899884259259263-1.85011574074073
52124124.468171296296128.041666666667-3.57349537037038-0.468171296296305
53120120.211226851852125.375-5.16377314814815-0.211226851851862
54113115.176504629630122.625-7.44849537037037-2.17650462962962
55120119.759837962963119.791666666667-0.03182870370370350.240162037037052
56121119.933449074074116.9166666666673.016782407407411.06655092592594
57115113.239004629630114.041666666667-0.8026620370370351.76099537037038
58119113.600115740741111.3333333333332.26678240740745.39988425925927
59106105.169560185185108.833333333333-3.663773148148140.83043981481481
6098102.426504629630106.75-4.32349537037037-4.42650462962962
61106109.801504629630105.0833333333334.7181712962963-3.80150462962963
62116119.239004629630103.33333333333315.9056712962963-3.23900462962963
6393100.475115740741101.375-0.899884259259263-7.47511574074073
649495.593171296296399.1666666666667-3.57349537037038-1.59317129629628
659091.877893518518597.0416666666667-5.16377314814815-1.87789351851853
669388.00983796296395.4583333333333-7.448495370370374.99016203703705
6710094.218171296296394.25-0.03182870370370355.78182870370371
689996.18344907407493.16666666666673.016782407407412.81655092592594
699090.94733796296391.75-0.802662037037035-0.947337962962948
709192.05844907407489.79166666666672.2667824074074-1.05844907407408
718384.127893518518587.7916666666667-3.66377314814814-1.12789351851852
728381.75983796296386.0833333333333-4.323495370370371.24016203703704
739289.468171296296384.754.71817129629632.53182870370371
7410499.32233796296383.416666666666715.90567129629634.67766203703704
757181.68344907407482.5833333333333-0.899884259259263-10.6834490740741
766978.75983796296382.3333333333333-3.57349537037038-9.75983796296296
776776.752893518518581.9166666666667-5.16377314814815-9.7528935185185
787573.676504629629681.125-7.448495370370371.32349537037037
7986NANA-0.0318287037037035NA
8081NANA3.01678240740741NA
8188NANA-0.802662037037035NA
8287NANA2.2667824074074NA
8377NANA-3.66377314814814NA
8470NANA-4.32349537037037NA
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Aug/17/t128207396234tfnf4obmo3p63/17p9k1282073979.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Aug/17/t128207396234tfnf4obmo3p63/17p9k1282073979.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Aug/17/t128207396234tfnf4obmo3p63/27p9k1282073979.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Aug/17/t128207396234tfnf4obmo3p63/27p9k1282073979.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Aug/17/t128207396234tfnf4obmo3p63/3hy8m1282073979.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Aug/17/t128207396234tfnf4obmo3p63/3hy8m1282073979.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Aug/17/t128207396234tfnf4obmo3p63/4hy8m1282073979.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Aug/17/t128207396234tfnf4obmo3p63/4hy8m1282073979.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