Home » date » 2009 » Dec » 03 »

*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: Thu, 03 Dec 2009 10:51:35 -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/03/t1259862719c9l0dhvblrdtm1n.htm/, Retrieved Thu, 03 Dec 2009 18:52:03 +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/03/t1259862719c9l0dhvblrdtm1n.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 «
115.47 103.34 102.60 100.69 105.67 123.61 113.08 106.46 123.38 109.87 95.74 123.06 123.39 120.28 115.33 110.4 114.49 132.03 123.16 118.82 128.32 112.24 104.53 132.57 122.52 131.8 124.55 120.96 122.6 145.52 118.57 134.25 136.7 121.37 111.63 134.42 137.65 137.86 119.77 130.69 128.28 147.45 128.42 136.9 143.95 135.64 122.48 136.83 153.04 142.71 123.46 144.37 146.15 147.61 158.51 147.4 165.05 154.64 126.2 157.36 154.15 123.21 113.07 110.45 113.57 122.44 114.93 111.85 126.04 121.34
 
Output produced by software:


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


Estimated Parameters of Exponential Smoothing
ParameterValue
alpha0.558149525043339
beta0
gamma0.210439498485435


Interpolation Forecasts of Exponential Smoothing
tObservedFittedResiduals
13123.39118.3241426282055.06585737179483
14120.28117.8782059151422.40179408485788
15115.33114.3194902104571.01050978954348
16110.4110.420479837141-0.0204798371409112
17114.49114.805606426700-0.315606426700157
18132.03132.178508250469-0.148508250469234
19123.16122.5734258419370.586574158062803
20118.82116.0165459972622.80345400273828
21128.32134.036599918303-5.71659991830336
22112.24117.172439789972-4.93243978997194
23104.53100.2888749314934.24112506850672
24132.57130.0292809417292.54071905827124
25122.52132.249143709074-9.72914370907434
26131.8123.2976721262778.50232787372252
27124.55123.0146009596191.53539904038105
28120.96119.312692977981.64730702201990
29122.6124.601252316458-2.00125231645791
30145.52141.0488489424914.47115105750910
31118.57134.090577197526-15.5205771975257
32134.25118.74963015220215.5003698477983
33136.7143.064243217082-6.36424321708157
34121.37125.911514687526-4.54151468752563
35111.63110.09912816571.53087183430006
36134.42138.168699121546-3.74869912154617
37137.65135.7372400171021.91275998289802
38137.86134.9789045870972.88109541290305
39119.77130.910540695208-11.1405406952082
40130.69120.14396848729210.5460315127081
41128.28130.060093438373-1.78009343837269
42147.45147.2329519261300.217048073869762
43128.42136.041367904197-7.62136790419717
44136.9127.9937750519478.9062249480534
45143.95146.594836496423-2.64483649642332
46135.64131.6875754498303.95242455017018
47122.48121.1807045343321.29929546566818
48136.83148.630112000102-11.8001120001017
49153.04142.23117889790110.8088211020988
50142.71146.528214288553-3.81821428855315
51123.46137.416862989954-13.9568629899545
52144.37127.09483987136617.2751601286337
53146.15139.6207072465086.52929275349192
54147.61161.617145485194-14.0071454851938
55158.51141.75749677886116.7525032211392
56147.4148.850950253000-1.45095025300023
57165.05160.5971093304424.4528906695584
58154.64150.2648730844384.37512691556196
59126.2139.747237942662-13.5472379426617
60157.36157.692040353663-0.332040353663331
61154.15159.796247726105-5.64624772610517
62123.21153.548831671235-30.3388316712351
63113.07128.692290509669-15.6222905096693
64110.45120.344750532434-9.89475053243387
65113.57116.706564421809-3.13656442180904
66122.44131.398473696496-8.9584736964959
67114.93117.216856779711-2.28685677971127
68111.85111.990892577709-0.140892577709209
69126.04125.0172153389951.02278466100462
70121.34112.7632363624798.57676363752145


Extrapolation Forecasts of Exponential Smoothing
tForecast95% Lower Bound95% Upper Bound
71102.92427123133886.1005462509806119.747996211696
72129.659244039039110.392362704154148.926125373924
73131.454649736528110.021317971952152.887981501104
74126.062698762572102.662640970160149.462756554983
75119.50814717969194.2943077488146144.721986610568
76120.41274389092893.5071182151721147.318369566683
77122.92570310622794.4285508421546151.422855370299
78138.826946942014108.822569239426168.831324644602
79130.2658434344998.826414758425161.705272110555
80126.51582500172393.7040486152604159.327601388185
81139.728988847396105.600003163771173.85797453102
82127.60653315674892.2093205835683163.003745729928
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2009/Dec/03/t1259862719c9l0dhvblrdtm1n/1t2761259862690.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/03/t1259862719c9l0dhvblrdtm1n/1t2761259862690.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Dec/03/t1259862719c9l0dhvblrdtm1n/2py1x1259862690.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/03/t1259862719c9l0dhvblrdtm1n/2py1x1259862690.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Dec/03/t1259862719c9l0dhvblrdtm1n/3jlmb1259862690.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/03/t1259862719c9l0dhvblrdtm1n/3jlmb1259862690.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=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