Home » date » 2010 » Aug » 19 »

tijdreeks 1 - stap 32

*Unverified author*
R Software Module: /rwasp_exponentialsmoothing.wasp (opens new window with default values)
Title produced by software: Exponential Smoothing
Date of computation: Thu, 19 Aug 2010 10:42:04 +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/Aug/19/t1282214511zpbbv5mfk4x9qxm.htm/, Retrieved Thu, 19 Aug 2010 12:41:57 +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/Aug/19/t1282214511zpbbv5mfk4x9qxm.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:
Vanhille Olivier
 
Dataseries X:
» Textbox « » Textfile « » CSV «
568 567 566 564 584 583 568 558 559 559 560 562 563 552 552 555 575 567 548 541 544 546 551 550 546 532 523 528 555 543 525 517 519 521 520 516 509 494 484 482 508 500 480 467 471 482 481 477 471 455 441 434 459 448 432 414 415 423 425 427 415 399 386 377 397 379 361 350 348 363 367 365 354 327 312 307 335 317 298 286 288 303 310 301 293 264 255 251 279 253 233 226 232 245 250 242 230 196 188 181 212 186 166 155 157 173 182 182 168 131 114 106 134 103 83 74 83 96 95 100
 
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'George Udny Yule' @ 72.249.76.132


Estimated Parameters of Exponential Smoothing
ParameterValue
alpha0.159879826158029
beta0.162679015015255
gamma1


Interpolation Forecasts of Exponential Smoothing
tObservedFittedResiduals
13563569.183250874616-6.18325087461562
14552557.33439358698-5.33439358698047
15552556.374463218462-4.37446321846176
16555558.303105875734-3.30310587573388
17575577.116827516407-2.1168275164066
18567567.905907590769-0.905907590769061
19548554.850008677484-6.8500086774842
20541542.925582471361-1.92558247136083
21544542.8147942048011.18520579519884
22546542.0162316568423.98376834315786
23551542.5347840132678.46521598673348
24550545.2408633109844.75913668901569
25546541.9527071716914.04729282830931
26532532.708499398416-0.708499398415938
27523533.276144824115-10.2761448241147
28528534.876877616726-6.87687761672566
29555553.0767194309471.92328056905274
30543545.669373155249-2.66937315524876
31525527.816738128259-2.81673812825886
32517520.826727169917-3.82672716991749
33519522.764195053015-3.76419505301465
34521523.181445422551-2.18144542255106
35520525.856627034538-5.85662703453795
36516522.412863367555-6.4128633675549
37509515.867723666687-6.86772366668686
38494500.312420258103-6.3124202581027
39484490.873109716892-6.87310971689237
40482494.018407219926-12.0184072199262
41508515.274577405886-7.27457740588579
42500501.478023083515-1.47802308351476
43480483.202757856554-3.2027578565536
44467474.053853723052-7.0538537230521
45471473.343060449829-2.34306044982924
46482473.1521969413028.84780305869788
47481472.8191258745558.18087412544503
48477470.077443089096.92255691090969
49471464.7964807643176.20351923568319
50455452.3309588799982.66904112000202
51441444.170547781539-3.17054778153914
52434443.216200539286-9.2162005392857
53459466.306458446974-7.30645844697403
54448457.692182392112-9.69218239211187
55432437.813469603639-5.81346960363891
56414425.445136318417-11.4451363184170
57415426.804306564024-11.8043065640240
58423432.465801311299-9.46580131129872
59425427.301500995212-2.30150099521234
60427420.5487511174136.4512488825871
61415413.5587974423191.44120255768121
62399397.4561669503201.54383304968047
63386384.0172640085121.98273599148757
64377377.73218555922-0.732185559219772
65397398.680810987198-1.68081098719796
66379388.62806665606-9.62806665606001
67361372.49138231528-11.4913823152800
68350355.035453869911-5.03545386991073
69348355.036203170460-7.03620317045954
70363360.3815987496552.61840125034513
71367361.4516391559315.54836084406901
72365361.9629472853333.03705271466686
73354350.8145304025183.18546959748193
74327336.391564304689-9.39156430468944
75312322.255834734169-10.2558347341690
76307311.454649951764-4.45464995176371
77335325.4110061232399.58899387676075
78317311.6592298173825.34077018261831
79298297.8310463463520.168953653647634
80286288.385916173362-2.38591617336215
81288286.237972790251.76202720975016
82303297.6400037907335.35999620926719
83310300.2225209761979.77747902380327
84301299.0426435182591.95735648174099
85293289.2027005633753.79729943662483
86264268.258173423532-4.25817342353236
87255256.057995209247-1.05799520924688
88251252.00795861768-1.00795861767980
89279273.2089231975245.7910768024758
90253258.322202851802-5.32220285180227
91233241.385436755265-8.3854367552646
92226229.815310740906-3.81531074090634
93232229.6195837208472.38041627915322
94245240.2685683945664.73143160543427
95250244.2558972974185.7441027025823
96242236.6796484944765.32035150552414
97230229.7058157318060.294184268194044
98196206.5070530395-10.5070530394999
99188196.735807264228-8.73580726422759
100181190.901480569547-9.90148056954718
101212207.7059977227444.29400227725611
102186187.684545379428-1.6845453794281
103166171.783155564777-5.78315556477665
104155164.367775272895-9.36777527289519
105157164.786971595525-7.78697159552459
106173169.5171736957623.48282630423765
107182170.08587171443711.9141282855631
108182163.28884935081618.7111506491844
109168155.84973409014412.1502659098561
110131133.946072823694-2.94607282369441
111114127.413737722008-13.4137377220083
112106119.818643675952-13.8186436759520
113134134.805710996569-0.805710996569218
114103115.910168634481-12.910168634481
1158399.5139545307705-16.5139545307705
1167488.240643099221-14.2406430992211
1178384.105161574591-1.10516157459108
1189687.99446751860258.00553248139747
1199588.39410008299226.60589991700779
12010083.100509050091216.8994909499088


Extrapolation Forecasts of Exponential Smoothing
tForecast95% Lower Bound95% Upper Bound
12173.79597979265560.10552734069687.486432244614
12253.881206276340340.036477955376167.7259345973045
12344.054430169739329.999704392910658.109155946568
12438.157553001027623.79223261532252.5228733867332
12543.5367074332428.014558727583059.058856138897
12629.987432585165814.593767844117845.3810973262138
12721.16668071182705.7059045294770936.6274568941770
12815.7140742154541-0.20755986403336031.6357082949415
12913.0351101467714-4.6916506035795530.7618708971223
1308.66861068109625-12.075677030974429.4128983931669
1311.24913105866199-21.607833730788324.1060958481123
132-7.5657434885315-30.084662511677414.9531755346144
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Aug/19/t1282214511zpbbv5mfk4x9qxm/1j73q1282214521.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Aug/19/t1282214511zpbbv5mfk4x9qxm/1j73q1282214521.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Aug/19/t1282214511zpbbv5mfk4x9qxm/2bglt1282214521.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Aug/19/t1282214511zpbbv5mfk4x9qxm/2bglt1282214521.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Aug/19/t1282214511zpbbv5mfk4x9qxm/3bglt1282214521.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Aug/19/t1282214511zpbbv5mfk4x9qxm/3bglt1282214521.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