Home » date » 2009 » Dec » 21 »

*The author of this computation has been verified*
R Software Module: /rwasp_exponentialsmoothing.wasp (opens new window with default values)
Title produced by software: Exponential Smoothing
Date of computation: Mon, 21 Dec 2009 03:03:08 -0700
 
Cite this page as follows:
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL http://www.freestatistics.org/blog/date/2009/Dec/21/t1261389948vskc4804ohc0ca7.htm/, Retrieved Mon, 21 Dec 2009 11:05:52 +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/2009/Dec/21/t1261389948vskc4804ohc0ca7.htm/},
    year = {2009},
}
@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 = {2009},
    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 «
43.9 51 51.9 54.3 50.3 57.2 48.8 41.1 58 63 53.8 54.7 55.5 56.1 69.6 69.4 57.2 68 53.3 47.9 60.8 61.7 57.8 51.4 50.5 48.1 58.7 54 56.1 60.4 51.2 50.7 56.4 53.3 52.6 47.7 49.5 48.5 55.3 49.8 57.4 64.6 53 41.5 55.9 58.4 53.5 50.6 58.5 49.1 61.1 52.3 58.4 65.5 61.7 45.1 52.1 59.3 57.9 45 64.9 63.8 69.4 71.1 62.9 73.5 62.7 51.9 73.3 66.7 62.5 70.3
 
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.319439681255854
beta0.0705399226443017
gamma0.308746635913248


Interpolation Forecasts of Exponential Smoothing
tObservedFittedResiduals
1355.550.50347770493324.99652229506683
1456.152.93090387576463.16909612423542
1569.667.41026604459452.1897339554055
1669.468.82743644835860.572563551641409
1757.257.5918281764854-0.391828176485433
186869.248561695987-1.24856169598704
1953.356.1312008204423-2.83120082044229
2047.946.48142535859551.41857464140452
2160.865.9179045817852-5.11790458178524
2261.768.8827932795695-7.18279327956947
2357.856.45448129207051.34551870792954
2451.457.6349180982275-6.23491809822752
2550.557.3730444907888-6.87304449078883
2648.155.1563646158473-7.05636461584727
2758.764.9441678879978-6.24416788799776
285462.3658765867787-8.36587658677867
2956.148.77616731071497.32383268928515
3060.460.5812181735006-0.181218173500596
3151.248.32804907849132.87195092150872
3250.741.6888856993629.01111430063799
3356.460.7141894843056-4.31418948430564
3453.362.7446818597275-9.44468185972755
3552.651.63334984708260.966650152917438
3647.750.7075133651127-3.00751336511274
3749.550.7747339240367-1.27473392403672
3848.549.9777604796206-1.47776047962063
3955.361.0194842702603-5.71948427026027
4049.857.9313000808969-8.13130008089692
4157.447.80931387306169.5906861269384
4264.658.35075973339086.24924026660916
435348.80961365002954.19038634997052
4441.543.7468642303466-2.24686423034662
4555.955.09293495403460.80706504596536
4658.457.28172549613681.11827450386321
4753.551.77436103636991.72563896363014
4850.650.28391224367320.316087756326816
4958.551.93615741082686.56384258917316
5049.153.8659092798134-4.76590927981338
5161.163.885962510168-2.78596251016796
5252.361.3344169240577-9.03441692405772
5358.454.48801094547293.91198905452712
5465.563.00519359739812.49480640260189
5561.751.453916267640910.2460837323591
5645.146.563595653662-1.46359565366196
5752.160.0928581605871-7.99285816058714
5859.359.6462840826926-0.346284082692634
5957.953.63519644466574.26480355533431
604552.613709154218-7.61370915421795
6164.952.853750913302812.0462490866972
6263.854.05525893787589.74474106212422
6369.470.8485591519473-1.44855915194728
6471.167.31374145614483.78625854385518
6562.967.6864678546306-4.78646785463059
6673.574.8326800239706-1.33268002397057
6762.762.21983220908030.480167790919722
6851.950.81060245389521.08939754610485
6973.365.36712570356427.93287429643581
7066.773.0028707355137-6.30287073551372
7162.565.4940084963394-2.99400849633942
7270.359.032844249352311.2671557506477


Extrapolation Forecasts of Exponential Smoothing
tForecast95% Lower Bound95% Upper Bound
7371.938476695521666.137526635427377.7394267556158
7468.389226067725361.601323559508675.177128575942
7581.6361682965673.094881158404990.1774554347152
7679.513368074380470.129547186732988.897188962028
7776.557060984126166.452414624461986.6617073437904
7887.834718811831375.5501329540012100.119304669661
7974.064652377685462.450582064361585.6787226910093
8060.674401006035749.851325655042471.497476357029
8179.256478639721264.681239544758593.8317177346838
8281.610792117473865.654206594893497.567377640054
8376.100353951014760.157834997611192.0428729044182
8473.136065953552756.30187821714289.9702536899635
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2009/Dec/21/t1261389948vskc4804ohc0ca7/1qld11261389785.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/21/t1261389948vskc4804ohc0ca7/1qld11261389785.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Dec/21/t1261389948vskc4804ohc0ca7/259641261389785.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/21/t1261389948vskc4804ohc0ca7/259641261389785.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Dec/21/t1261389948vskc4804ohc0ca7/3llyp1261389785.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/21/t1261389948vskc4804ohc0ca7/3llyp1261389785.ps (open in new window)


 
Parameters (Session):
par1 = 12 ; par2 = Triple ; par3 = multiplicative ;
 
Parameters (R input):
par1 = 12 ; par2 = Triple ; par3 = multiplicative ;
 
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=0, beta=0)
if (par2 == 'Double') fit <- HoltWinters(x, gamma=0)
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