Home » date » 2009 » Aug » 19 »

dennis volkaerts - opg 10

*Unverified author*
R Software Module: rwasp_exponentialsmoothing.wasp (opens new window with default values)
Title produced by software: Exponential Smoothing
Date of computation: Wed, 19 Aug 2009 07:05:28 -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/19/t1250687174o5mb7o0zbun0udv.htm/, Retrieved Wed, 19 Aug 2009 15:06:14 +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/19/t1250687174o5mb7o0zbun0udv.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 «
17.23 17.36 17.39 17.29 17.28 17.4 17.51 17.54 17.64 17.65 17.5 17.37 17.56 17.49 17.61 17.79 17.83 17.56 17.95 18.09 18.38 18.38 18.44 18.84 19.01 19.06 19.06 18.97 18.98 19.41 19.55 19.64 19.71 19.48 19.48 19.41 19.25 19.14 19.21 19.3 19.53 19.14 19.16 19.24 19.38 19.27 19.27 19.07 19.15 19.24 19.36 19.57 19.59 19.36 19.46 19.65 19.46 19.51 19.64 19.64 19.69 19.28 19.67 19.65 19.6 19.53 19.64 19.67 19.81 19.73 19.87 19.97 20.12 19.94 20.31 20.13 20.22 20.38 20.44 20.34 20.14 19.97 19.82 19.98 20.12
 
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.930756132630198
beta0
gamma0


Interpolation Forecasts of Exponential Smoothing
tObservedFittedResiduals
317.3917.360.0300000000000011
417.2917.3879226839789-0.0979226839789078
517.2817.2967805453419-0.0167805453419270
617.417.28116194985600.118838050143950
717.5117.39177119381730.118228806182657
817.5417.50181338022540.0381866197745993
917.6417.53735581076500.102644189234976
1017.6517.63289251937430.0171074806256648
1117.517.6488154118805-0.148815411880523
1217.3717.5103045546428-0.140304554642835
1317.5617.37971522997310.180284770026930
1417.4917.5475163852955-0.057516385295461
1517.6117.4939826569550.116017343045012
1617.7917.60196651048560.188033489514407
1717.8317.77697983399100.0530201660090164
1817.5617.8263286786569-0.266328678656947
1917.9517.57844162770170.371558372298303
2018.0917.92427186134840.165728138651563
2118.3818.07852434274780.301475657252233
2218.3818.3591246595740.0208753404259987
2318.4418.37855451069620.061445489303761
2418.8418.43574527668820.404254723311819
2519.0118.81200783955540.197992160444620
2619.0618.99629025710190.0637097428980837
2719.0619.05558849101260.00441150898739906
2818.9719.0596945300568-0.089694530056775
2918.9818.97621079614300.00378920385695380
3019.4118.97973762087070.430262379129307
3119.5519.38020696888540.169793031114647
3219.6419.53824287387320.101757126126820
3319.7119.63295394305450.0770460569454592
3419.4819.7046650330515-0.224665033051505
3519.4819.4955566757512-0.0155566757512489
3619.4119.4810772043924-0.0710772043924344
3719.2519.4149216605140-0.164921660513965
3819.1419.2614198135870-0.121419813587035
3919.2119.14840757746810.0615924225319127
4019.319.20573510246320.0942648975367852
4119.5319.29347273393730.236527266062666
4219.1419.5136219373594-0.373621937359417
4319.1619.1658710278770-0.00587102787696381
4419.2419.16040653267560.0795934673243615
4519.3819.23448864050510.145511359494911
4619.2719.3699242307223-0.0999242307223334
4719.2719.2769191401792-0.00691914017916773
4819.0719.2704791080249-0.200479108024879
4919.1519.08388194876650.0661180512335058
5019.2419.14542173042960.0945782695703627
5119.3619.23345103484580.126548965154196
5219.5719.35123726024110.218762739758922
5319.5919.55485202186270.0351479781373207
5419.3619.5875662180635-0.227566218063544
5519.4619.37575756502140.0842424349785631
5619.6519.45416672800540.195833271994562
5719.4619.6364397468874-0.176439746887411
5819.5119.47221737043220.0377826295677686
5919.6419.50738378460930.132616215390673
6019.6419.63081714037040.00918285962959686
6119.6919.63936414328570.0506358567142691
6219.2819.6864937774535-0.406493777453520
6319.6719.30814720121260.361852798787361
6419.6519.64494391279340.0050560872066221
6519.619.6496498969681-0.0496498969680523
6619.5319.6034379508806-0.0734379508805816
6719.6419.53508512773070.104914872269315
6819.6719.63273528849950.0372647115005371
6919.8119.66741964725930.142580352740715
7019.7319.8001271849653-0.0701271849652798
7119.8719.73485587749480.135144122505245
7219.9719.86064209830540.109357901694558
7320.1219.96242763595920.157572364040782
7419.9420.1090890801232-0.169089080123214
7520.3119.95170838183770.358291618162262
7620.1320.2851905027123-0.155190502712259
7720.2220.14074599058690.0792540094131375
7820.3820.21451214588370.165487854116328
7920.4420.36854098097830.071459019021745
8020.3420.4350519011645-0.095051901164485
8120.1420.3465817612375-0.20658176123748
8219.9720.1543045200761-0.18430452007615
8319.8219.9827619577438-0.162761957743808
8419.9819.83127026741490.148729732585139
8520.1219.96970137812290.150298621877074


Extrapolation Forecasts of Exponential Smoothing
tForecast95% Lower Bound95% Upper Bound
8620.109592742160919.785837136404620.4333483479172
8720.109592742160919.667300993961720.5518844903601
8820.109592742160919.574404654857420.6447808294643
8920.109592742160919.49540174006320.7237837442588
9020.109592742160919.425461990531920.7937234937899
9120.109592742160919.362037270245320.8571482140764
9220.109592742160919.303588100823520.9155973834982
9320.109592742160919.249099987906820.9700854964150
9420.109592742160919.197862475914221.0213230084076
9520.109592742160919.149355075405021.0698304089167
9620.109592742160919.103182947433521.1160025368882
9720.109592742160919.059038139491621.1601473448302
 
Charts produced by software:
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2009/Aug/19/t1250687174o5mb7o0zbun0udv/1gs8g1250687124.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2009/Aug/19/t1250687174o5mb7o0zbun0udv/1gs8g1250687124.ps (open in new window)


http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2009/Aug/19/t1250687174o5mb7o0zbun0udv/2l7le1250687124.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2009/Aug/19/t1250687174o5mb7o0zbun0udv/2l7le1250687124.ps (open in new window)


http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2009/Aug/19/t1250687174o5mb7o0zbun0udv/3x6ww1250687124.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2009/Aug/19/t1250687174o5mb7o0zbun0udv/3x6ww1250687124.ps (open in new window)


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