Home » date » 2010 » Nov » 29 »

W8 (3)

*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, 29 Nov 2010 10:02:53 +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/Nov/29/t1291025503wlnua7wqlwucc2f.htm/, Retrieved Mon, 29 Nov 2010 11:11:50 +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/Nov/29/t1291025503wlnua7wqlwucc2f.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 «
37 30 47 35 30 43 82 40 47 19 52 136 80 42 54 66 81 63 137 72 107 58 36 52 79 77 54 84 48 96 83 66 61 53 30 74 69 59 42 65 70 100 63 105 82 81 75 102 121 98 76 77 63 37 35 23 40 29 37 51 20 28 13 22 25 13 16 13 16 17 9 17 25 14 8 7 10 7 10 3
 
Output produced by software:


Summary of computational transaction
Raw Inputview raw input (R code)
Raw Outputview raw output of R engine
Computing time5 seconds
R Server'Gwilym Jenkins' @ 72.249.127.135


Estimated Parameters of Exponential Smoothing
ParameterValue
alpha0.380859354912001
beta0.0316088853012633
gamma0.733581043315084


Interpolation Forecasts of Exponential Smoothing
tObservedFittedResiduals
138065.953525641025714.0464743589743
144232.44671481726019.55328518273991
155447.13530513160956.86469486839045
166660.590894908015.40910509199001
178179.72389409402461.2761059059754
186369.4231643277681-6.42316432776809
19137111.48776994845825.5122300515419
207280.1890659314056-8.18906593140558
2110786.45632367155220.5436763284479
225868.1223642893241-10.1223642893241
233697.153764642369-61.1537646423691
2452157.471510088699-105.471510088699
257965.853803915793113.1461960842069
267728.650494978248748.3495050217513
275456.0480501431291-2.04805014312910
288464.494919076742319.5050809232577
294886.3359268092791-38.3359268092791
309656.191372995912939.8086270040871
3183129.664803267216-46.6648032672161
326653.99739133105812.002608668942
336179.6754118037384-18.6754118037384
345330.674606122684922.3253938773151
353047.4750331630982-17.4750331630982
3674103.414328539587-29.4143285395875
376994.6690520639822-25.6690520639822
385958.23468268167360.765317318326439
394243.609557805132-1.60955780513198
406561.0081831412343.99181685876599
417049.478803349931820.5211966500682
4210076.760334137812323.2396658621877
4363103.965837074180-40.9658370741803
4410556.50154942884248.498450571158
458281.97154136393560.0284586360644283
468158.767430267256822.2325697327432
477557.505438458549117.4945615414509
48102121.811391006691-19.8113910066906
49121119.0110215464311.98897845356879
5098106.036128029648-8.03612802964805
517687.7937238475118-11.7937238475118
5277104.548576897235-27.5485768972347
536388.8253943324124-25.8253943324124
543799.4433230770057-62.4433230770057
553563.5759025308631-28.5759025308631
562360.3350961492543-37.3350961492543
574028.937578654051311.0624213459487
582917.991147653551511.0088523464485
59378.1378362318391328.8621637681609
605157.8014044626805-6.8014044626805
612067.986280314369-47.9862803143689
622828.951675237226-0.95167523722598
63139.313210565713963.68678943428604
642222.6070517338644-0.607051733864424
652516.05057370461658.94942629538355
661321.8230856739742-8.82308567397422
671620.9469405271599-4.94694052715987
681322.1988348562020-9.19883485620204
691623.3093821664651-7.30938216646515
70174.9308234847238512.0691765152762
7193.192179909837565.80782009016244
721727.201755489461-10.2017554894610
732516.66938856479288.33061143520722
741420.4077763690616-6.40777636906155
7580.6939026256049847.30609737439502
76713.3553977851489-6.3553977851489
77108.820287664657131.17971233534287
7873.338225050026453.66177494997355
79108.904549139224121.09545086077588
80310.5263066432461-7.5263066432461


Extrapolation Forecasts of Exponential Smoothing
tForecast95% Lower Bound95% Upper Bound
8113.1518860780379-37.446598918895763.7503710749715
826.46657662737189-47.897222023720360.8303752784641
83-2.75000728509995-60.846725736882455.3467111666825
8411.6688643515566-50.140253426642173.4779821297553
8513.4546037022310-52.055546076287878.9647534807497
867.24134529398266-61.96565455853776.4483451465023
87-3.81105338954830-76.716447137432969.0943403583363
88-0.232709452860554-76.842660726262776.3772418205416
891.05592991450302-79.268509091258781.3803689202648
90-3.78144524582828-87.833400150117980.2705096584614
91-0.852758842772003-88.64782466259586.942306977051
92-3.6547344525488-95.210646124488587.9011772193909
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Nov/29/t1291025503wlnua7wqlwucc2f/1g3b21291024966.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/29/t1291025503wlnua7wqlwucc2f/1g3b21291024966.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/29/t1291025503wlnua7wqlwucc2f/2g3b21291024966.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/29/t1291025503wlnua7wqlwucc2f/2g3b21291024966.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/29/t1291025503wlnua7wqlwucc2f/39cam1291024966.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/29/t1291025503wlnua7wqlwucc2f/39cam1291024966.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