Home » date » 2009 » Aug » 18 »

*Unverified author*
R Software Module: rwasp_exponentialsmoothing.wasp (opens new window with default values)
Title produced by software: Exponential Smoothing
Date of computation: Tue, 18 Aug 2009 11:06:24 -0600
 
Cite this page as follows:
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL http://www.freestatistics.org/blog/date/2009/Aug/18/t1250615254x9hwel9591pflhe.htm/, Retrieved Tue, 18 Aug 2009 19:07:34 +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/2009/Aug/18/t1250615254x9hwel9591pflhe.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 «
6430 5124 4836 4629 4597 4490 4517 4560 4135 4559 4739 4886 5605 4616 4997 4607 4882 4555 4462 4476 4277 4369 4492 5183 6039 4923 4953 4892 4614 4363 4675 4556 4217 4664 4601 5428 5607 4869 5174 5031 4671 4491 4504 4615 4582 4800 4775 5791 5818 4714 4915 4598 4407 4383 4412 4274 4236 4637 4534 5271 5467 5204 5752 4724 4623 4451 4138 4140 4169 4603 4434 5185
 
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


Estimated Parameters of Exponential Smoothing
ParameterValue
alpha0.82052932810292
beta0
gamma0


Interpolation Forecasts of Exponential Smoothing
tObservedFittedResiduals
251246430-1306
348365358.38869749759-522.388697497587
446294929.75345053133-300.753450531332
545974682.97642384222-85.976423842223
644904612.43024655427-122.430246554272
745174511.972638609625.02736139037916
845604516.097736073443.9022639266004
941354552.12083119529-417.120831195291
1045594209.86095583689349.139044163113
1147394496.33978115854242.660218841458
1248864695.44960748183190.550392518169
1356054851.80179302451753.198206975489
1446165469.82301172243-853.823011722433
1549974769.23618959501227.763810404987
1646074956.12307591278-349.123075912778
1748824669.65735300884212.342646991158
1845554843.89072247209-288.890722472092
1944624606.8474120669-144.847412066899
2044764487.9958623662-11.9958623661996
2142774478.15290547885-201.152905478847
2243694313.1010471003455.8989528996617
2344924358.96777736475133.032222635245
2451834468.12461761969714.875382380309
2560395054.70083480152984.299165198476
2649235862.3471674741-939.347167474095
2749535091.58526729119-138.585267291194
2848924977.87199103579-85.8719910357868
2946144907.41150392833-293.411503928332
3043634666.65875975235-303.658759752350
3146754417.49784164019257.502158359812
3245564628.78591462422-72.7859146242163
3342174569.06293700225-352.062937002252
3446644280.18497185385383.815028146147
3546014595.116459014415.88354098558557
3654284599.94407694618828.055923053817
3756075279.38824712117327.611752878825
3848695548.20329858946-679.203298589458
3951744990.89707235256183.102927647437
4050315141.13839454879-110.138394548792
4146715050.76661167134-379.766611671337
4244914739.15696896073-248.156968960732
4345044535.53689795533-31.536897955325
4446154509.65994826559105.340051734408
4545824596.09455013755-14.0945501375527
4648004584.52955838327215.470441616726
4747754761.3293750690913.6706249309145
4857914772.54652375841018.45347624160
4958185608.217470323209.782529676997
5047145780.3501884466-1066.3501884466
5149154905.378584798099.62141520191108
5245984913.27323814911-315.273238149112
5344074654.58229988179-247.582299881789
5443834451.43376170961-68.4337617096089
5544124395.2818531944716.7181468055314
5642744408.99958295994-134.999582959937
5742364298.22846585965-62.2284658596454
5846374247.16818457896389.831815421045
5945344567.03662215953-33.0366221595268
6052714539.92910477618731.07089522382
6154675139.79421522978327.205784770219
6252045408.27615795868-204.276157958678
6357525240.6615793214511.338420678602
6447245660.22975007402-936.22975007402
6546234892.02578229582-269.025782295819
6644514671.28223790627-220.282237906268
6741384490.53420124403-352.534201244031
6841404201.26954996397-61.2695499639667
6941694150.9960872988618.0039127011351
7046034165.76882569075437.231174309249
7144344524.52982737237-90.5298273723702
7251854450.24744894525734.752551054754


Extrapolation Forecasts of Exponential Smoothing
tForecast95% Lower Bound95% Upper Bound
735053.133465984114177.565829939285928.70110202894
745053.133465984113920.54404157186185.72289039642
755053.133465984113711.903089317946394.36384265028
765053.133465984113531.608230474186574.65870149404
775053.133465984113370.522649040686735.74428292754
785053.133465984113223.565407589866882.70152437836
795053.133465984113087.564998772147018.70193319607
805053.133465984112960.384193304877145.88273866335
815053.133465984112840.501630973837265.76530099439
825053.133465984112726.788745977547379.47818599068
835053.133465984112618.380937429337487.88599453889
845053.133465984112514.598456514017591.66847545421
 
Charts produced by software:
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2009/Aug/18/t1250615254x9hwel9591pflhe/1zd971250615179.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2009/Aug/18/t1250615254x9hwel9591pflhe/1zd971250615179.ps (open in new window)


http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2009/Aug/18/t1250615254x9hwel9591pflhe/24iso1250615179.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2009/Aug/18/t1250615254x9hwel9591pflhe/24iso1250615179.ps (open in new window)


http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2009/Aug/18/t1250615254x9hwel9591pflhe/3ynyc1250615179.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2009/Aug/18/t1250615254x9hwel9591pflhe/3ynyc1250615179.ps (open in new window)


 
Parameters (Session):
par1 = 12 ; par2 = Single ; par3 = additive ;
 
Parameters (R input):
par1 = 12 ; par2 = Single ; 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=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