Home » date » 2010 » Jan » 26 »

eigen reeks opgave 8

*Unverified author*
R Software Module: /rwasp_exponentialsmoothing.wasp (opens new window with default values)
Title produced by software: Exponential Smoothing
Date of computation: Tue, 26 Jan 2010 12:22:55 -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/26/t1264533846xtugkgavdu4vxb8.htm/, Retrieved Tue, 26 Jan 2010 20:24:10 +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/26/t1264533846xtugkgavdu4vxb8.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:
KEYWORD: KDGP2W62
 
Dataseries X:
» Textbox « » Textfile « » CSV «
124.9 122.7 148.1 176.9 234.6 254.6 279.7 275.8 283 295.4 297.6 276.8 250.1 239.1 258.9 276.1 264.1 265.5 287.7 285.1 304.5 301.5 274.2 258.6 253.9 269.6 266.9 269.6 257.9 258.2 254.7 237.2 267.2 228.8 196.3 194.8 186.6 176.7 162.1 154.9 150.1 150.5 143.6 143.8 141.5 147.9 151.4 144.6 140.4 139.5 138.1 136.7 130 128.5 130.4 125.7 121.7 129.9 129.6 128.2 119.7 112.2 105.6 101.2 94.9 95.1 93.1 91.4 89.8 85.9 89.7 91.6 88.6
 
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'Gwilym Jenkins' @ 72.249.127.135


Estimated Parameters of Exponential Smoothing
ParameterValue
alpha0.357504192131878
beta0.200940707428541
gamma1


Interpolation Forecasts of Exponential Smoothing
tObservedFittedResiduals
13250.1220.44169337606929.6583066239315
14239.1224.45805383380314.6419461661969
15258.9254.3953380911944.50466190880641
16276.1278.565436115028-2.46543611502847
17264.1272.737418316742-8.63741831674241
18265.5278.494903533154-12.9949035331539
19287.7329.644386077925-41.9443860779247
20285.1302.44780896338-17.3478089633801
21304.5294.49839420666410.0016057933361
22301.5302.961663352859-1.46166335285932
23274.2300.409264001131-26.2092640011305
24258.6267.805861633489-9.20586163348867
25253.9254.671095080908-0.771095080908253
26269.6231.55978000997338.0402199900274
27266.9258.4286595937798.4713404062208
28269.6274.903334892304-5.30333489230384
29257.9259.256148990486-1.35614899048585
30258.2260.500983430093-2.3009834300928
31254.7293.325817658484-38.6258176584837
32237.2279.809388422839-42.6093884228392
33267.2275.276565757883-8.07656575788258
34228.8263.488854501053-34.6888545010526
35196.3224.347562875663-28.0475628756633
36194.8193.0697150772741.73028492272587
37186.6181.1077298461875.49227015381257
38176.7177.465404544223-0.765404544222918
39162.1160.9692474253871.13075257461261
40154.9154.948151715486-0.0481517154864548
41150.1133.07197463005217.0280253699478
42150.5130.95905131558019.5409486844196
43143.6140.4998511860953.10014881390546
44143.8134.5846137440549.21538625594638
45141.5169.732914322033-28.2329143220331
46147.9131.15932070304816.7406792969519
47151.4115.88423663174535.5157633682552
48144.6132.24182630456012.3581736954404
49140.4133.0390322885607.3609677114396
50139.5132.7211030198036.7788969801968
51138.1127.35915799019810.7408420098019
52136.7131.9254495343734.77455046562679
53130131.000411103601-1.00041110360144
54128.5131.017307672957-2.5173076729574
55130.4127.4849600689762.91503993102424
56125.7130.795178791412-5.09517879141232
57121.7141.101605045243-19.4016050452431
58129.9139.549591732372-9.64959173237216
59129.6129.975991063662-0.375991063661814
60128.2119.118315720559.08168427944997
61119.7115.7929474024793.90705259752085
62112.2113.877599890108-1.67759989010841
63105.6107.441813150535-1.84181315053543
64101.2102.176391693773-0.976391693773166
6594.993.57180373878721.32819626121280
6695.191.70069302697673.3993069730233
6793.192.452958741330.647041258669972
6891.488.32203814799463.07796185200536
6989.891.461924309446-1.66192430944595
7085.9102.895263679034-16.9952636790344
7189.796.5038267266136-6.8038267266136
7291.688.81295526121872.78704473878125
7388.678.84862413478789.75137586521217


Extrapolation Forecasts of Exponential Smoothing
tForecast95% Lower Bound95% Upper Bound
7474.790446756996643.0784411307395106.502452383254
7568.325332544364933.8140733432684102.836591745461
7663.883137131845425.8880535529317101.878220710759
7756.787183056233314.670335201470398.9040309109964
7855.35538439100848.53643543212566102.174333349891
7952.46333574766810.419496725554822104.507174769781
8048.9557412045722-8.7837595524323106.695241961577
8147.0215638417077-16.8396901621975110.882817845613
8248.3885074809065-21.9831494899258118.760164451739
8355.032860911676-22.2067691501459132.272490973498
8456.8372050763588-27.6021831471619141.276593299880
8551.0515583301586-40.8978792867074143.000995947025
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Jan/26/t1264533846xtugkgavdu4vxb8/1rjub1264533772.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Jan/26/t1264533846xtugkgavdu4vxb8/1rjub1264533772.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Jan/26/t1264533846xtugkgavdu4vxb8/2nvza1264533772.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Jan/26/t1264533846xtugkgavdu4vxb8/2nvza1264533772.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Jan/26/t1264533846xtugkgavdu4vxb8/31ddw1264533772.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Jan/26/t1264533846xtugkgavdu4vxb8/31ddw1264533772.ps (open in new window)


 
Parameters (Session):
par1 = 12 ; par2 = Triple ; par3 = additive ;
 
Parameters (R input):
par1 = 12 ; par2 = Triple ; par3 = additive ;
 
R code (references can be found in the software module):
par1 <- as.numeric(par1)
if (par2 == 'Single') K <- 1
if (par2 == 'Double') K <- 2
if (par2 == 'Triple') K <- par1
nx <- length(x)
nxmK <- nx - K
x <- ts(x, frequency = par1)
if (par2 == 'Single') fit <- HoltWinters(x, gamma=F, beta=F)
if (par2 == 'Double') fit <- HoltWinters(x, gamma=F)
if (par2 == 'Triple') fit <- HoltWinters(x, seasonal=par3)
fit
myresid <- x - fit$fitted[,'xhat']
bitmap(file='test1.png')
op <- par(mfrow=c(2,1))
plot(fit,ylab='Observed (black) / Fitted (red)',main='Interpolation Fit of Exponential Smoothing')
plot(myresid,ylab='Residuals',main='Interpolation Prediction Errors')
par(op)
dev.off()
bitmap(file='test2.png')
p <- predict(fit, par1, prediction.interval=TRUE)
np <- length(p[,1])
plot(fit,p,ylab='Observed (black) / Fitted (red)',main='Extrapolation Fit of Exponential Smoothing')
dev.off()
bitmap(file='test3.png')
op <- par(mfrow = c(2,2))
acf(as.numeric(myresid),lag.max = nx/2,main='Residual ACF')
spectrum(myresid,main='Residals Periodogram')
cpgram(myresid,main='Residal Cumulative Periodogram')
qqnorm(myresid,main='Residual Normal QQ Plot')
qqline(myresid)
par(op)
dev.off()
load(file='createtable')
a<-table.start()
a<-table.row.start(a)
a<-table.element(a,'Estimated Parameters of Exponential Smoothing',2,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Parameter',header=TRUE)
a<-table.element(a,'Value',header=TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'alpha',header=TRUE)
a<-table.element(a,fit$alpha)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'beta',header=TRUE)
a<-table.element(a,fit$beta)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'gamma',header=TRUE)
a<-table.element(a,fit$gamma)
a<-table.row.end(a)
a<-table.end(a)
table.save(a,file='mytable.tab')
a<-table.start()
a<-table.row.start(a)
a<-table.element(a,'Interpolation Forecasts of Exponential Smoothing',4,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'t',header=TRUE)
a<-table.element(a,'Observed',header=TRUE)
a<-table.element(a,'Fitted',header=TRUE)
a<-table.element(a,'Residuals',header=TRUE)
a<-table.row.end(a)
for (i in 1:nxmK) {
a<-table.row.start(a)
a<-table.element(a,i+K,header=TRUE)
a<-table.element(a,x[i+K])
a<-table.element(a,fit$fitted[i,'xhat'])
a<-table.element(a,myresid[i])
a<-table.row.end(a)
}
a<-table.end(a)
table.save(a,file='mytable1.tab')
a<-table.start()
a<-table.row.start(a)
a<-table.element(a,'Extrapolation Forecasts of Exponential Smoothing',4,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'t',header=TRUE)
a<-table.element(a,'Forecast',header=TRUE)
a<-table.element(a,'95% Lower Bound',header=TRUE)
a<-table.element(a,'95% Upper Bound',header=TRUE)
a<-table.row.end(a)
for (i in 1:np) {
a<-table.row.start(a)
a<-table.element(a,nx+i,header=TRUE)
a<-table.element(a,p[i,'fit'])
a<-table.element(a,p[i,'lwr'])
a<-table.element(a,p[i,'upr'])
a<-table.row.end(a)
}
a<-table.end(a)
table.save(a,file='mytable2.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