Home » date » 2010 » Dec » 21 »

Triple exponential smoothing (additive)

*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: Tue, 21 Dec 2010 20:38:51 +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/Dec/21/t12929639171ayg83hp2n6dw8l.htm/, Retrieved Tue, 21 Dec 2010 21:38:40 +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/Dec/21/t12929639171ayg83hp2n6dw8l.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 «
27951 29781 32914 33488 35652 36488 35387 35676 34844 32447 31068 29010 29812 30951 32974 32936 34012 32946 31948 30599 27691 25073 23406 22248 22896 25317 26558 26471 27543 26198 24725 25005 23462 20780 19815 19761 21454 23899 24939 23580 24562 24696 23785 23812 21917 19713 19282 18788 21453 24482 27474 27264 27349 30632 29429 30084 26290 24379 23335 21346 21106 24514 28353 30805 31348 34556 33855 34787 32529 29998 29257 28155 30466 35704 39327 39351 42234 43630 43722 43121 37985 37135 34646 33026 35087 38846 42013 43908 42868 44423 44167 43636 44382 42142 43452 36912 42413 45344 44873 47510 49554 47369 45998 48140 48441 44928 40454 38661 37246 36843 36424 37594 38144 38737 34560 36080 33508 35462 33374 32110 35533 35532 37903 36763 40399 44164 44496 43110 43880 43930 44327
 
Output produced by software:


Summary of computational transaction
Raw Inputview raw input (R code)
Raw Outputview raw output of R engine
Computing time13 seconds
R Server'George Udny Yule' @ 72.249.76.132


Estimated Parameters of Exponential Smoothing
ParameterValue
alpha0.916247210448925
beta0.041682819544113
gamma0.53947629784894


Interpolation Forecasts of Exponential Smoothing
tObservedFittedResiduals
132981230527.3862179487-715.386217948708
143095131047.1674454637-96.1674454637323
153297433169.383341243-195.383341243003
163293633227.9392475456-291.939247545641
173401234322.0847316208-310.084731620802
183294633220.2617826689-274.261782668931
193194831908.49530196139.5046980390071
203059931745.7252381622-1146.72523816215
212769129406.3215077756-1715.32150777561
222507324987.181871904485.8181280955978
232340623310.442282326495.5577176736297
242224821091.85941596441156.14058403558
252289622791.8229862359104.177013764132
262531723993.16589062211323.83410937788
272655827368.8649921360-810.864992136041
282647126792.5121484789-321.512148478851
292754327790.9994892360-247.999489236041
302619826682.3094967578-484.309496757764
312472525118.8710407817-393.871040781738
322500524415.4801313731589.519868626885
332346223617.5811942989-155.581194298909
342078020744.864501859535.1354981404584
351981519056.1264748894758.873525110637
361976117552.55732907172208.44267092833
372145420268.68105423791185.31894576205
382389922656.53709181021242.46290818983
392493925998.9335164244-1059.93351642441
402358025344.6750313823-1764.67503138226
412456225097.2654055416-535.265405541566
422469623776.7960171806919.203982819385
432378523619.1160900398165.883909960183
442381223610.1162954216201.883704578398
452191722545.6616580007-628.661658000696
461971319352.3161063817360.683893618301
471928218111.20726680021170.79273319976
481878817182.93121662051605.06878337952
492145319409.32185196042043.67814803963
502448222728.34527171101753.65472828905
512747426596.7309766793877.26902332074
522726427921.2115785828-657.211578582781
532734929021.9809662332-1672.98096623325
543063226959.26901085663672.7309891434
552942929630.0949590114-201.094959011432
563008429612.0942239926471.905776007392
572629029093.4487988619-2803.44879886193
582437924205.0313594758173.968640524181
592333523075.1865792973259.813420702729
602134621542.7966352568-196.796635256756
612110622280.1808332974-1174.18083329741
622451422656.98038671721857.01961328281
632835326603.65861689241749.34138310758
643080528714.32933991932090.67066008069
653134832448.3776406776-1100.37764067759
663455631335.14864738143220.85135261857
673385533582.9567129103272.043287089655
683478734212.9907907347574.009209265343
693252933827.9229410715-1298.92294107154
702999830698.0259899003-700.02598990026
712925728983.3606357208273.639364279239
722815527655.6317350005499.368264999532
733046629225.92595665081240.07404334917
743570432283.15379820693420.84620179306
753932738048.96023027581278.03976972422
763935140116.3661225652-765.366122565225
774223441353.4633928287880.536607171263
784363042590.20543039531039.79456960472
794372242962.8122646198759.187735380183
804312144327.8605201136-1206.86052011357
813798542433.4629753998-4448.4629753998
823713536531.5932570855603.406742914478
833464636191.6924389163-1545.69243891629
843302633274.2265354958-248.226535495778
853508734231.4758443396855.524155660401
863884637058.6770297551787.32297024497
874201341192.3506086852820.649391314837
884390842692.27472610731215.72527389266
894286845838.4964479147-2970.49644791472
904442343426.4468771271996.553122872894
914416743617.6148199731549.385180026882
924363644564.4476014687-928.447601468695
934438242652.16081787541729.83918212465
944214242748.8402027503-606.84020275026
954345241266.17069285822185.82930714175
963691242032.0562119294-5120.05621192943
974241338595.04385175503817.95614824496
984534444311.47504055021032.52495944980
994487347813.8719279095-2940.87192790951
1004751045845.48580582151664.51419417854
1014955449191.2271995566362.772800443418
1024736950117.2841589157-2748.28415891575
1034599846818.7952928201-820.795292820098
1044814046352.84616543871787.15383456134
1054844147061.95818847641379.04181152360
1064492846731.3736734092-1803.37367340922
1074045444232.5967428259-3778.59674282591
1083866138929.7351696376-268.735169637628
1093724640253.0966116523-3007.09661165235
1103684339241.0996663667-2398.09966636668
1113642438940.5066795011-2516.50667950107
1123759437105.0737663897488.926233610327
1133814438806.0182783147-662.018278314725
1143873738104.5573333210632.442666678951
1153456037571.8648115244-3011.86481152441
1163608034713.63334827691366.36665172310
1173350834500.1350615145-992.13506151447
1183546231243.99132075044218.00867924961
1193337433793.8255223271-419.825522327112
1203211031476.0730985790633.926901421037
1213553333286.30355153042246.69644846962
1223553237099.7813944856-1567.78139448558
1233790337570.5120480186332.487951981377
1243676338605.9608480421-1842.96084804205
1254039938153.96364235542245.03635764461
1264416440321.24215416323842.75784583678
1274449642834.61170603231661.38829396766
1284311044903.8144325821-1793.81443258212
1294388042015.31178841131864.68821158871
1304393042048.30569663351881.69430336646
1314432742594.89399847111732.10600152887


Extrapolation Forecasts of Exponential Smoothing
tForecast95% Lower Bound95% Upper Bound
13242725.585465146439416.205016849046034.9659134437
13344432.771881200839857.975317735749007.5684446659
13446334.487389815240702.441477832651966.5333017978
13548706.544126483642121.904346032555291.1839069347
13649705.352493917542230.505829141557180.1991586935
13751563.348738037243238.719891086559887.9775849879
13852096.745514545342949.736780266461243.7542488242
13951194.814433408641244.424887649661145.2039791675
14051726.383787054640985.860297225562466.9072768836
14150855.992596074639334.469416885262377.515775264
14249319.256931978937022.828339684361615.6855242735
14348201.141471381535133.594895228161268.6880475349
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Dec/21/t12929639171ayg83hp2n6dw8l/1rczh1292963917.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/21/t12929639171ayg83hp2n6dw8l/1rczh1292963917.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/21/t12929639171ayg83hp2n6dw8l/2rczh1292963917.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/21/t12929639171ayg83hp2n6dw8l/2rczh1292963917.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/21/t12929639171ayg83hp2n6dw8l/323gk1292963917.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/21/t12929639171ayg83hp2n6dw8l/323gk1292963917.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