Home » date » 2010 » Jul » 26 »

Kelly Janbroers - 2de zit - Stap 32/A

*Unverified author*
R Software Module: /rwasp_exponentialsmoothing.wasp (opens new window with default values)
Title produced by software: Exponential Smoothing
Date of computation: Mon, 26 Jul 2010 15:48:44 +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/Jul/26/t1280159334cud36wf2rskay6s.htm/, Retrieved Mon, 26 Jul 2010 17:48:54 +0200
 
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/Jul/26/t1280159334cud36wf2rskay6s.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 «
33 32 31 29 49 48 33 23 24 24 25 27 24 21 15 21 49 48 35 36 51 50 61 63 61 62 58 65 93 94 86 88 102 107 121 127 125 128 117 127 160 162 153 160 177 178 196 212 212 211 204 216 248 250 240 249 275 277 286 302 290 290 277 285 311 300 291 299 332 337 343 360 353 351 341 348 381 358 353 358 399 409 407 419 418 421 414 424 463 437 430 436 474 489 482 492 502 500 493 504 538 516 502 501 541 571 559 569 576 573 562 570 597 573 562 556 600 630 624 634
 
Output produced by software:


Summary of computational transaction
Raw Inputview raw input (R code)
Raw Outputview raw output of R engine
Computing time2 seconds
R Server'Sir Ronald Aylmer Fisher' @ 193.190.124.24


Estimated Parameters of Exponential Smoothing
ParameterValue
alpha0.116508597215365
beta0.113960080374117
gamma0.923119969726914


Interpolation Forecasts of Exponential Smoothing
tObservedFittedResiduals
132426.4444669311186-2.44446693111864
142122.7999103475503-1.79991034755028
151515.5071479699010-0.507147969901043
162120.48639043327280.513609566727155
174945.13584072224323.86415927775681
184841.83805251667436.16194748332573
193536.3824260342733-1.38242603427332
203626.40117712165979.5988228783403
215130.461879939621720.5381200603783
225034.964458720263315.0355412797367
236139.908889188661521.0911108113385
246347.359079512626915.6409204873731
256141.747448840777619.2525511592224
266239.612406558976522.3875934410235
275830.924810308435627.0751896915644
286548.839665261101816.1603347388982
2993120.376007733544-27.3760077335443
3094115.441865223909-21.4418652239095
318685.48186431547910.518135684520871
328884.38681820173083.61318179826920
33102112.134675530090-10.1346755300897
34107105.1407632408391.85923675916068
35121121.118271453613-0.118271453613005
36127121.0771150270695.92288497293131
37125110.94539262437814.0546073756224
38128106.35233614866321.6476638513365
3911790.964998862566126.0350011374339
40127101.77286738347125.2271326165286
41160157.8922126708982.10778732910242
42162161.2869357592470.713064240753056
43153144.3172252481308.68277475187034
44160146.83494888252313.1650511174767
45177174.6759060405622.32409395943776
46178181.105546752881-3.10554675288139
47196203.976018348845-7.97601834884512
48212210.4728699302121.52713006978769
49212202.6466102111889.35338978881151
50211202.1487833227878.85121667721307
51204178.10541478294425.8945852170555
52216190.2158564970725.7841435029301
53248244.5102368255743.48976317442575
54250246.4507833250213.54921667497905
55240229.37289088386310.6271091161367
56249236.93756378876612.0624362112345
57275263.04238536772711.9576146322730
58277265.71255214223411.2874478577659
59286294.649798731673-8.64979873167329
60302315.135086901385-13.1350869013848
61290309.893093353792-19.8930933537925
62290303.117698760301-13.1176987603006
63277283.486602623844-6.4866026238443
64285292.823866971079-7.82386697107933
65311334.270974687350-23.2709746873496
66300330.791503884563-30.7915038845633
67291308.866917739733-17.8669177397330
68299313.146783649465-14.1467836494645
69332338.698860574392-6.69886057439152
70337335.0988643722961.90113562770421
71343345.341446975476-2.34144697547589
72360362.791377332174-2.79137733217431
73353348.0038375339574.99616246604324
74351346.9450060116184.05499398838157
75341329.82148483705511.1785151629454
76348339.6589700725088.34102992749234
77381373.8410835032577.1589164967433
78358364.443136986266-6.4431369862657
79353352.9522578797940.0477421202064647
80358363.236019478418-5.23601947841757
81399401.904778684521-2.90477868452052
82409405.7752366898113.22476331018885
83407413.224574255489-6.22457425548936
84419432.469211640472-13.4692116404721
85418420.232241543497-2.23224154349737
86421416.0844032743914.91559672560919
87414401.66233554937712.3376644506232
88424409.49363141732714.5063685826732
89463448.37587503461614.6241249653841
90437424.03234811269612.9676518873035
91430418.53176411050511.4682358894946
92436426.5528249270839.44717507291728
93474476.553445223035-2.553445223035
94489487.0091468959821.99085310401750
95482486.231795117647-4.23179511764693
96492502.246427752703-10.2464277527030
97502499.1173532096862.88264679031357
98500501.693261568068-1.69326156806761
99493490.6373778357572.36262216424342
100504500.2478274204123.75217257958786
101538544.266158879228-6.26615887922787
102516510.5395158400275.46048415997313
103502500.6877092950271.31229070497284
104501505.760629563508-4.76062956350842
105541549.401803617438-8.40180361743785
106571563.8869245502487.11307544975182
107559556.528108034362.47189196563954
108569569.123138142177-0.123138142176572
109576578.319365692353-2.31936569235324
110573575.369278243249-2.36927824324903
111562565.481496797421-3.48149679742119
112570576.077233259365-6.07723325936456
113597614.63374958803-17.6337495880302
114573584.699471116764-11.6994711167645
115562566.285335599852-4.28533559985181
116556564.350268451656-8.35026845165567
117600608.180435407701-8.18043540770122
118630637.202970029505-7.20297002950474
119624621.3565148055792.64348519442080
120634631.3552942288842.64470577111581


Extrapolation Forecasts of Exponential Smoothing
tForecast95% Lower Bound95% Upper Bound
121638.301890061408617.075085764316659.528694358501
122633.76228918743612.33697205899655.187606315869
123620.694976661165599.049663884489642.340289437841
124629.116610441239607.17979435738651.053426525099
125660.63537349351638.280785539932682.989961447088
126634.123589831142611.512970567519656.734209094764
127621.106080396055598.169561865774644.042598926336
128615.071615963833591.747445347015638.395786580651
129664.024070526507639.839811170905688.20832988211
130697.4299466292672.366044308721722.493848949679
131689.212738480854663.625475474793714.800001486914
132699.38549502688682.363862116969716.40712793679
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Jul/26/t1280159334cud36wf2rskay6s/1p5n61280159319.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Jul/26/t1280159334cud36wf2rskay6s/1p5n61280159319.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Jul/26/t1280159334cud36wf2rskay6s/2he581280159319.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Jul/26/t1280159334cud36wf2rskay6s/2he581280159319.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Jul/26/t1280159334cud36wf2rskay6s/3he581280159319.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Jul/26/t1280159334cud36wf2rskay6s/3he581280159319.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=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