Home » date » 2009 » Dec » 11 »

WS9

*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: Fri, 11 Dec 2009 05:54:10 -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/11/t1260536095mudrt4t5ev04ag7.htm/, Retrieved Fri, 11 Dec 2009 13:54:59 +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/11/t1260536095mudrt4t5ev04ag7.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 «
7.55 7.55 7.59 7.59 7.59 7.57 7.57 7.59 7.6 7.64 7.64 7.76 7.76 7.76 7.77 7.83 7.94 7.94 7.94 8.09 8.18 8.26 8.28 8.28 8.28 8.29 8.3 8.3 8.31 8.33 8.33 8.34 8.48 8.59 8.67 8.67 8.67 8.71 8.72 8.72 8.72 8.74 8.74 8.74 8.74 8.79 8.85 8.86 8.87 8.92 8.96 8.97 8.99 8.98 8.98 9.01 9.01 9.03 9.05 9.05
 
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.848800087938736
beta0
gamma1


Interpolation Forecasts of Exponential Smoothing
tObservedFittedResiduals
137.767.611976880966420.148023119033584
147.767.735081276175690.0249187238243094
157.777.754936108956190.0150638910438081
167.837.811423012455710.0185769875442885
177.947.918252314763190.0217476852368153
187.947.922073349214330.0179266507856743
197.947.96741586091488-0.0274158609148749
208.097.980289430440560.109710569559438
218.188.100265538692930.0797344613070692
228.268.22568016433890.0343198356610923
238.288.261804991763660.0181950082363436
248.288.40836139135682-0.128361391356817
258.288.32404003197007-0.0440400319700682
268.298.261787241691450.0282127583085447
278.38.280495663835110.0195043361648874
288.38.34201160340643-0.0420116034064311
298.318.40140676092787-0.0914067609278693
308.338.306247101132610.0237528988673894
318.338.34917362973838-0.0191736297383756
328.348.39073301192205-0.0507330119220519
338.488.369534760995030.11046523900497
348.598.514748954005710.075251045994289
358.678.582060113797460.0879398862025411
368.678.76881379003755-0.0988137900375463
378.678.72246943279367-0.0524694327936661
388.718.661691964196980.0483080358030215
398.728.694147103543740.0258528964562625
408.728.75183648926944-0.0318364892694394
418.728.81502799922603-0.0950279992260281
428.748.732480997820150.00751900217984769
438.748.75429194053674-0.0142919405367401
448.748.79615133617384-0.0561513361738371
458.748.79515626383475-0.0551562638347498
468.798.79477670626116-0.00477670626116122
478.858.795305006547020.0546949934529781
488.868.92645100310957-0.0664510031095702
498.878.91479209814778-0.0447920981477825
508.928.87490929804960.0450907019504001
518.968.900171014113460.0598289858865417
528.978.97779367639901-0.00779367639900919
538.999.05305911344782-0.0630591134478191
548.989.01251553925291-0.0325155392529144
558.988.99644891115725-0.0164489111572497
569.019.03049561520607-0.0204956152060696
579.019.06028623396056-0.0502862339605645
589.039.07230834976358-0.0423083497635783
599.059.049369183783320.000630816216675711
609.059.11698370075069-0.0669837007506882


Extrapolation Forecasts of Exponential Smoothing
tForecast95% Lower Bound95% Upper Bound
619.108442107179988.992462453719899.22442176064008
629.119551629611448.967582370731469.2715208884914
639.107727604705698.927188277568049.28826693184334
649.124066080206628.918693333277279.32943882713597
659.198220453779278.96972050101559.42672040654304
669.215437309706998.96697684718079.46389777223328
679.228886407350848.96210297512729.49566983957449
689.276664333663258.991928557709989.5614001096165
699.319583403997999.018048243197869.6211185647981
709.3762372439299.058357482671649.69411700518637
719.395164244094149.062843891338889.7274845968494
729.452842139932265.9652656477190112.9404186321455
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2009/Dec/11/t1260536095mudrt4t5ev04ag7/13ef41260536048.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/11/t1260536095mudrt4t5ev04ag7/13ef41260536048.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Dec/11/t1260536095mudrt4t5ev04ag7/2ymlk1260536048.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/11/t1260536095mudrt4t5ev04ag7/2ymlk1260536048.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Dec/11/t1260536095mudrt4t5ev04ag7/39pn71260536048.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/11/t1260536095mudrt4t5ev04ag7/39pn71260536048.ps (open in new window)


 
Parameters (Session):
par1 = 12 ;
 
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