Home » date » 2008 » May » 28 »

Michiel van Schaik - Exponential Smoothing - Gemiddelde consumptieprijs hotelkamer

R Software Module: rwasp_exponentialsmoothing.wasp (opens new window with default values)
Title produced by software: Exponential Smoothing
Date of computation: Wed, 28 May 2008 09:46:46 -0600
 
Cite this page as follows:
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL http://www.freestatistics.org/blog/date/2008/May/28/t1211989669tuub98ag5xx4r12.htm/, Retrieved Wed, 28 May 2008 17:47:52 +0200
 
User-defined keywords:
 
Dataseries X:
» Textbox « » Textfile « » CSV «
65,05 65,84 66,6 67,55 68,07 69,06 69,06 69,11 69,29 69,38 69,28 69,75 69,9 70,21 70,48 71,55 72,18 72,64 72,77 72,74 73,13 73,44 73,34 73,34 73,81 74,26 74,72 75,11 75,26 75,89 75,91 76,43 76,56 76,76 76,76 76,56 76,82 77,09 77,51 77,76 77,86 77,89 77,94 77,99 78,17 78,91 78,87 78,88 79,08 79,41 79,51 79,73 80,38 80,56 80,46 80,45 80,58 80,68 80,52 81,49 81,66 81,95 82,3 82,4 83,14 83,17 83,11 83,21 83,33 83,88 83,8 83,73
 
Text written by user:
 
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.917656813396868
beta0.0281982938785126
gamma1


Interpolation Forecasts of Exponential Smoothing
tObservedFittedResiduals
1369.968.02802916666671.87197083333331
1470.2170.10975244390180.100247556098211
1570.4870.5228191591618-0.0428191591618372
1671.5571.5855750578989-0.0355750578988676
1772.1872.2048913359693-0.0248913359692864
1872.6472.6829508405107-0.0429508405107413
1972.7772.819576506402-0.0495765064019906
2072.7472.7696725588243-0.0296725588243021
2173.1373.1435157866442-0.0135157866442341
2273.4473.4722523138908-0.0322523138907655
2373.3473.4212939002112-0.0812939002111506
2473.3473.436145217428-0.0961452174280453
2573.8173.8711076112687-0.0611076112687385
2674.2674.02244121005440.237558789945581
2774.7274.54268732731490.177312672685119
2875.1175.8066967954683-0.696696795468341
2975.2675.8017541082026-0.541754108202568
3075.8975.77219353562350.117806464376542
3175.9176.0281231170997-0.118123117099742
3276.4375.88751158100870.542488418991283
3376.5676.7730937913862-0.213093791386186
3476.7676.8973401886155-0.137340188615454
3576.7676.72338645008270.0366135499172628
3676.5676.8257419725764-0.265741972576421
3776.8277.0840978456703-0.264097845670292
3877.0977.04463655734250.0453634426575462
3977.5177.34946647339120.160533526608802
4077.7678.491589561936-0.731589561936005
4177.8678.431962709569-0.571962709569021
4277.8978.3927865840641-0.502786584064097
4377.9478.0075341024115-0.0675341024115284
4477.9977.91678840837210.0732115916278957
4578.1778.2464209483747-0.0764209483747322
4678.9178.44276295402630.467237045973690
4778.8778.79401084502530.0759891549747493
4878.8878.86470494560040.0152950543995871
4979.0879.345466161293-0.265466161293062
5079.4179.29457026772830.115429732271693
5179.5179.6393325341397-0.129332534139706
5279.7380.4006491921818-0.67064919218177
5380.3880.37031717682390.0096828231761208
5480.5680.8458673950013-0.285867395001333
5580.4680.6764046146996-0.216404614699641
5680.4580.43767635647890.0123236435211425
5780.5880.6745779044181-0.0945779044181023
5880.6880.8740192199891-0.194019219989102
5980.5280.5441279248172-0.0241279248171793
6081.4980.47324422387351.01675577612649
6181.6681.8310911402325-0.171091140232477
6281.9581.88181261028760.0681873897124063
6382.382.1454949553830.154505044617025
6482.483.1124748864526-0.712474886452625
6583.1483.08847117085670.051528829143308
6683.1783.567857163918-0.397857163918033
6783.1183.288220157795-0.178220157794911
6883.2183.09122857686180.118771423138156
6983.3383.407626758217-0.077626758217022
7083.8883.6054904449820.274509555018000
7183.883.72271633189450.0772836681054514
7283.7383.836406682311-0.106406682310975


Extrapolation Forecasts of Exponential Smoothing
tForecast95% Lower Bound95% Upper Bound
7384.042504794995683.283118735890684.8018908541005
7484.251099366729683.207045755842485.2951529776167
7584.438719513118683.161232246488485.7162067797488
7685.16793167271683.683608000096186.6522553453358
7785.85448687139884.179807993270187.5291657495258
7886.242090810104884.388245155257888.0959364649517
7986.348438447479784.32345150359888.3734253913613
8086.346861425429184.156700053775388.537022797083
8186.542437160950384.191645783280988.8932285386198
8286.846881307056884.338976966464689.354785647649
8386.695207824957584.032939744740589.3574759051745
8486.720099224725283.905627017398189.5345714320524
 
Charts produced by software:
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/May/28/t1211989669tuub98ag5xx4r12/1yp7s1211989595.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/May/28/t1211989669tuub98ag5xx4r12/1yp7s1211989595.ps (open in new window)


http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/May/28/t1211989669tuub98ag5xx4r12/2rfny1211989595.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/May/28/t1211989669tuub98ag5xx4r12/2rfny1211989595.ps (open in new window)


http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/May/28/t1211989669tuub98ag5xx4r12/3wsvz1211989595.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/May/28/t1211989669tuub98ag5xx4r12/3wsvz1211989595.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