Home » date » 2010 » Jun » 06 »

IKO opgave 9 oe 3

*Unverified author*
R Software Module: /rwasp_decompose.wasp (opens new window with default values)
Title produced by software: Classical Decomposition
Date of computation: Sun, 06 Jun 2010 12:19:48 +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/Jun/06/t12758268303j8q1hn8np3dyqb.htm/, Retrieved Sun, 06 Jun 2010 14:20:30 +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/Jun/06/t12758268303j8q1hn8np3dyqb.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:
 
Dataseries X:
» Textbox « » Textfile « » CSV «
278,1 283,3 287 287,9 279,7 273,2 272,6 274,8 277,2 277,5 278,7 279 280,1 280,8 280,1 270,5 260 258,2 260,1 262,2 263,4 264,7 267,4 266,8 265,2 262,5 255 252,8 249,6 254,2 259,4 260,8 261,6 257,2 249,8 235,2 227,4 223,1 221,6 218,5 220,1 222,1 222,9 222,8 222,1 209 201,7 204,5 208,7 213 218,6 221,9 224,6 226,8 229,6 231,4 229,1 232,7 236,6 242,2 251,5 261,5 266,4 280,9 294,4 308,8 328,8 348,2 365,9 387,5 395,9 395,8
 
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
1278.1NANA-0.921250000000002NA
2283.3NANA-0.401249999999992NA
3287NANA-1.59208333333333NA
4287.9NANA-2.66791666666667NA
5279.7NANA-3.74125000000001NA
6273.2NANA-1.41125NA
7272.6280.847083333333279.1666666666671.68041666666666-8.24708333333325
8274.8282.709583333333279.1458333333333.56375-7.90958333333339
9277.2282.95125278.7541666666674.19708333333334-5.75125000000003
10277.5279.70875277.7416666666671.96708333333332-2.20875000000001
11278.7276.71875276.1958333333330.5229166666666751.98124999999999
12279273.55375274.75-1.196250000000005.44625000000002
13280.1272.682916666667273.604166666667-0.9212500000000027.41708333333332
14280.8272.157083333333272.558333333333-0.4012499999999928.64291666666668
15280.1269.86625271.458333333333-1.5920833333333310.2337500000000
16270.5267.682083333333270.35-2.667916666666672.81791666666669
17260265.604583333333269.345833333333-3.74125000000001-5.60458333333332
18258.2266.955416666667268.366666666667-1.41125-8.75541666666669
19260.1268.917916666667267.23751.68041666666666-8.81791666666663
20262.2269.417916666667265.8541666666673.56375-7.21791666666667
21263.4268.242916666667264.0458333333334.19708333333334-4.84291666666667
22264.7264.229583333333262.26251.967083333333320.470416666666665
23267.4261.614583333333261.0916666666670.5229166666666755.78541666666666
24266.8259.295416666667260.491666666667-1.196250000000007.50458333333336
25265.2259.374583333333260.295833333333-0.9212500000000025.82541666666668
26262.5259.807083333333260.208333333333-0.4012499999999922.69291666666669
27255258.482916666667260.075-1.59208333333333-3.48291666666665
28252.8257.019583333333259.6875-2.66791666666667-4.21958333333333
29249.6254.900416666667258.641666666667-3.74125000000001-5.30041666666659
30254.2255.180416666667256.591666666667-1.41125-0.980416666666656
31259.4255.380416666667253.71.680416666666664.01958333333334
32260.8254.047083333333250.4833333333333.563756.75291666666664
33261.6251.647083333333247.454.197083333333349.95291666666668
34257.2246.59625244.6291666666671.9670833333333210.6037500000000
35249.8242.49375241.9708333333330.5229166666666757.30625
36235.2238.207916666667239.404166666667-1.19625000000000-3.00791666666669
37227.4235.624583333333236.545833333333-0.921250000000002-8.22458333333333
38223.1233.040416666667233.441666666667-0.401249999999992-9.94041666666666
39221.6228.620416666667230.2125-1.59208333333333-7.02041666666665
40218.5223.890416666667226.558333333333-2.66791666666667-5.39041666666665
41220.1218.804583333333222.545833333333-3.741250000000011.29541666666668
42222.1217.85125219.2625-1.411254.24874999999997
43222.9218.884583333333217.2041666666671.680416666666664.01541666666665
44222.8219.567916666667216.0041666666673.563753.23208333333338
45222.1219.655416666667215.4583333333334.197083333333342.44458333333336
46209217.442083333333215.4751.96708333333332-8.44208333333327
47201.7216.327083333333215.8041666666670.522916666666675-14.6270833333333
48204.5214.99125216.1875-1.19625000000000-10.4912500000000
49208.7215.74125216.6625-0.921250000000002-7.04124999999996
50213216.89875217.3-0.401249999999992-3.89874999999998
51218.6216.357916666667217.95-1.592083333333332.24208333333334
52221.9216.56125219.229166666667-2.667916666666675.33874999999998
53224.6217.929583333333221.670833333333-3.741250000000016.67041666666665
54226.8223.284583333333224.695833333333-1.411253.51541666666665
55229.6229.730416666667228.051.68041666666666-0.130416666666690
56231.4235.417916666667231.8541666666673.56375-4.01791666666665
57229.1240.06375235.8666666666674.19708333333334-10.96375
58232.7242.28375240.3166666666671.96708333333332-9.58375
59236.6246.20625245.6833333333330.522916666666675-9.60624999999996
60242.2250.812083333333252.008333333333-1.19625000000000-8.61208333333329
61251.5258.637083333333259.558333333333-0.921250000000002-7.13708333333332
62261.5268.157083333333268.558333333333-0.401249999999992-6.65708333333328
63266.4277.532916666667279.125-1.59208333333333-11.1329166666667
64280.9288.607083333333291.275-2.66791666666667-7.70708333333334
65294.4300.62125304.3625-3.74125000000001-6.22125
66308.8315.98875317.4-1.41125-7.18874999999991
67328.8NANA1.68041666666666NA
68348.2NANA3.56375NA
69365.9NANA4.19708333333334NA
70387.5NANA1.96708333333332NA
71395.9NANA0.522916666666675NA
72395.8NANA-1.19625000000000NA
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Jun/06/t12758268303j8q1hn8np3dyqb/1a1tj1275826785.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Jun/06/t12758268303j8q1hn8np3dyqb/1a1tj1275826785.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Jun/06/t12758268303j8q1hn8np3dyqb/2a1tj1275826785.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Jun/06/t12758268303j8q1hn8np3dyqb/2a1tj1275826785.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Jun/06/t12758268303j8q1hn8np3dyqb/3ktt41275826785.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Jun/06/t12758268303j8q1hn8np3dyqb/3ktt41275826785.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Jun/06/t12758268303j8q1hn8np3dyqb/4ktt41275826785.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Jun/06/t12758268303j8q1hn8np3dyqb/4ktt41275826785.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