Home » date » 2009 » Dec » 11 »

*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 07:54:17 -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/t1260543419i303nhyq2eankvb.htm/, Retrieved Fri, 11 Dec 2009 15:57: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/11/t1260543419i303nhyq2eankvb.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 «
12610 10862 52929 56902 81776 87876 82103 72846 60632 33521 15342 7758 8668 13082 38157 58263 81153 88476 72329 75845 61108 37665 12755 2793 12935 19533 33404 52074 70735 69702 61656 82993 53990 32283 15686 2713 12842 19244 48488 54464 84192 84458 85793 75163 68212 49233 24302 5402 15058 33559 70358 85934 94452 129305 113882 107256 94274 57842 26611 14521
 
Output produced by software:


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


Estimated Parameters of Exponential Smoothing
ParameterValue
alpha0.0856933077971209
beta0.13396647530554
gamma0.210070820414823


Interpolation Forecasts of Exponential Smoothing
tObservedFittedResiduals
1386688907.30328460187-239.303284601869
141308213449.1526080878-367.152608087752
153815738868.975328155-711.975328154971
165826358778.8482637075-515.848263707492
178115381364.8054271865-211.805427186482
188847688927.2764167426-451.276416742636
197232979216.9136883901-6887.91368839011
207584569501.39269706696343.60730293307
216110858701.01054810822406.98945189181
223766532835.70178598584829.2982140142
231275515177.1948283943-2422.19482839429
2427937540.35851209685-4747.35851209685
25129357900.451592575245034.54840742476
261953312595.67824931856937.3217506815
273340438489.7169640263-5085.71696402632
285207457990.3263769827-5916.3263769827
297073579982.7780515793-9247.77805157925
306970286694.3243054436-16992.3243054436
316165674732.2227784424-13076.2227784424
328299367236.855635962815756.1443640372
335399056954.0077741194-2964.00777411941
343228332206.507881913876.492118086222
351568613825.10626006551860.89373993452
3627136346.59467777225-3633.59467777225
37128428567.82900638434274.1709936157
381924413325.41240008905918.58759991103
394848835681.922463776512806.0775362235
405446456636.8096885636-2172.80968856355
418419278736.64570310225455.35429689776
428445885922.5951108467-1464.59511084665
438579376259.3356966639533.66430333698
447516377088.2215200482-1925.22152004817
456821261158.90327142777053.09672857233
464923335869.73353217713363.266467823
472430216538.52749538547763.47250461458
4854026858.31393575847-1456.31393575847
491505812079.49107128522978.50892871475
503355918596.043912734514962.9560872655
517035851670.217885329618687.7821146704
528593477918.5619173888015.43808261192
5394452114340.475549731-19888.4755497311
54129305122437.0324864536867.96751354726
55113882114427.829459748-545.829459747649
56107256113081.087749923-5825.08774992335
579427493400.0780841639873.921915836094
585784257631.0282321771210.971767822877
592661126443.2844991541167.715500845927
60145219351.595898721915169.40410127809


Extrapolation Forecasts of Exponential Smoothing
tForecast95% Lower Bound95% Upper Bound
6119418.445646776515206.593500619823630.2977929332
6232321.965269454627477.87079146737166.0597474423
6378460.375948386470086.117951392886834.63394538
64109412.72297220597529.4342770695121296.011667341
65150387.317610425133341.551005209167433.084215641
66170851.430593421150344.425896335191358.435290508
67156846.912860079136833.576216431176860.249503727
68153451.626386335132794.137037318174109.115735352
69128706.729261203110376.448001256147037.010521149
7079195.354419408666939.799757187991450.9090816293
7136312.66011413129354.629568315843270.6906599462
7214105.845889763411799.888069043316411.8037104834
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2009/Dec/11/t1260543419i303nhyq2eankvb/11je31260543250.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/11/t1260543419i303nhyq2eankvb/11je31260543250.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Dec/11/t1260543419i303nhyq2eankvb/20opl1260543250.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/11/t1260543419i303nhyq2eankvb/20opl1260543250.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Dec/11/t1260543419i303nhyq2eankvb/3a2za1260543250.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/11/t1260543419i303nhyq2eankvb/3a2za1260543250.ps (open in new window)


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