Home » date » 2009 » Dec » 04 »

ws 9 theorie 2

*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, 04 Dec 2009 12:32:15 -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/04/t1259955185606htjzu5ua42i1.htm/, Retrieved Fri, 04 Dec 2009 20:33:09 +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/04/t1259955185606htjzu5ua42i1.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 «
100.01 103.84 104.48 95.43 104.80 108.64 105.65 108.42 115.35 113.64 115.24 100.33 101.29 104.48 99.26 100.11 103.52 101.18 96.39 97.56 96.39 85.10 79.77 79.13 80.84 82.75 92.55 96.60 96.92 95.32 98.52 100.22 104.91 103.10 97.13 103.42 111.72 118.11 111.62 100.22 102.03 105.76 107.68 110.77 105.44 112.26 114.07 117.90 124.72 126.42 134.73 135.79 143.36 140.37 144.74 151.98 150.92 163.38 154.43 146.66 157.95 162.10 180.42 179.57 171.58 185.43 190.64 203.00 202.36 193.41 186.17 192.24 209.60 206.41 209.82 230.37 235.80 232.07 244.64 242.19 217.48 209.39 211.73 221.00 203.11 214.71 224.19 238.04 238.36 246.24 259.87 249.97 266.48 282.98 306.31 301.73 314.62 332.62 355.51 370.32 408.13 433.58 440.51 386.29 342.84 254.97 203.42 170.09 174.03 167.85 177.01 188.19 211.20 240.91 230.26 251.25 241.66
 
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'Gwilym Jenkins' @ 72.249.127.135


Estimated Parameters of Exponential Smoothing
ParameterValue
alpha0.920153543184328
beta0
gamma1


Interpolation Forecasts of Exponential Smoothing
tObservedFittedResiduals
13101.29102.550463407594-1.26046340759406
14104.48104.602730522094-0.122730522094429
1599.2699.6753984574467-0.415398457446727
16100.11101.289862238172-1.17986223817176
17103.52105.559180439175-2.0391804391746
18101.18102.963286964500-1.78328696450015
1996.3994.89787311406551.49212688593451
2097.5697.8852964365457-0.325296436545713
2196.39103.119535295576-6.72953529557613
2285.194.6332701866511-9.53327018665112
2379.7786.0655769472826-6.29557694728264
2479.1369.35063674480699.77936325519308
2580.8478.75493561197572.08506438802434
2682.7583.1372271531058-0.387227153105812
2792.5578.784053340280413.7659466597196
2896.693.16952744648663.43047255351337
2996.92101.377299851777-4.45729985177677
3095.3296.564852267570-1.24485226756993
3198.5289.55925308059198.96074691940808
32100.2299.30757644026210.912423559737888
33104.91105.290777026023-0.380777026023466
34103.1102.1915929707190.908407029281022
3597.13103.729976358562-6.59997635856163
36103.4285.923209636714817.4967903632852
37111.72101.9773835784089.74261642159215
38118.11114.3573944706273.7526055293734
39111.62113.850245539943-2.230245539943
40100.22113.035460127926-12.8154601279261
41102.03105.902646682722-3.87264668272198
42105.76101.9061009372493.85389906275057
43107.6899.89132804858637.78867195141372
44110.77108.0648696571102.70513034289016
45105.44116.205272156857-10.7652721568571
46112.26103.6295795184958.63042048150494
47114.07111.719037848182.35096215181997
48117.9102.25921975182215.6407802481777
49124.72115.9322353820068.78776461799356
50126.42127.359399204059-0.939399204058844
51134.73121.79517068882712.9348293111733
52135.79134.1832787295831.60672127041653
53143.36143.2228805716040.137119428395977
54140.37143.942195012112-3.57219501211239
55144.74133.89460311932310.8453968806771
56151.98144.9518474901977.02815250980285
57150.92157.886378739035-6.9663787390354
58163.38150.17718294092413.2028170590756
59154.43162.202177118590-7.7721771185904
60146.66140.7733395670045.88666043299571
61157.95144.75525091196313.1947490880372
62162.1160.3337042169741.76629578302607
63180.42157.46502637803822.9549736219623
64179.57178.2926864849711.27731351502882
65171.58189.580964914839-18.0009649148392
66185.43173.54580531557211.8841946844279
67190.64177.29122806907613.3487719309241
68203190.81558501792912.1844149820714
69202.36209.395850986913-7.03585098691346
70193.41203.538037353040-10.1280373530402
71186.17192.212178995332-6.04217899533177
72192.24170.86145790627721.3785420937233
73209.6189.56210205162520.0378979483749
74206.41211.583459744775-5.17345974477499
75209.82203.1950428966166.62495710338416
76230.37207.06972047595623.3002795240444
77235.8239.475619716213-3.67561971621279
78232.07240.352155936019-8.28215593601874
79244.64223.9807502912920.65924970871
80242.19244.617380800953-2.42738080095259
81217.48249.497595313175-32.0175953131751
82209.39220.472571918630-11.0825719186305
83211.73208.5086987830793.22130121692123
84221195.93294186297325.0670581370273
85203.11217.721859797283-14.6118597972831
86214.71205.7770935834818.93290641651939
87224.19211.22594558275312.9640544172466
88238.04222.07443789381015.9655621061904
89238.36245.841137318728-7.48113731872832
90246.24242.8899073646073.35009263539334
91259.87239.0606922603120.8093077396901
92249.97258.024929564917-8.05492956491722
93266.48255.20529142997911.2747085700207
94282.98268.29444972695214.6855502730481
95306.31281.26522737342125.0447726265787
96301.73284.53830592082417.1916940791764
97314.62294.50168828710620.1183117128938
98332.62318.62634926305213.9936507369484
99355.51328.08049558086627.4295044191337
100370.32352.34039572006317.979604279937
101408.13380.48515842140527.6448415785947
102433.58414.69419897462118.8858010253791
103440.51422.81328106255717.6967189374425
104386.29435.441061327431-49.1510613274305
105342.84400.222905935782-57.3829059357818
106254.97351.509404824083-96.5394048240827
107203.42262.739092371358-59.3190923713579
108170.09193.980810218526-23.8908102185262
109174.03168.3901056442535.63989435574683
110167.85176.012232952996-8.1622329529965
111177.01166.82679946962710.1832005303732
112188.19174.89221223549613.2977877645044
113211.2192.89056886466018.3094311353403
114240.91213.43372481363127.4762751863690
115230.26233.155433530494-2.89543353049393
116251.25225.15019624465826.0998037553421
117241.66254.445458589964-12.7854585899641


Extrapolation Forecasts of Exponential Smoothing
tForecast95% Lower Bound95% Upper Bound
118241.267117570009205.495043998350277.039191141669
119242.915317003428194.071266861086291.759367145769
120229.23257997572172.282020809341286.183139142099
121227.813035915904162.157040952779293.469030879029
122229.770997095142155.641243594516303.900750595768
123229.728772663041148.396942294544311.060603031539
124228.513633017624140.898044244985316.129221790262
125236.037082278896139.504752943477332.569411614314
126240.828593914365136.688345597029344.968842231701
127232.842577490626126.509019616902339.176135364351
128229.589120588057119.311451647316339.866789528798
129231.457709368691112.476456961079350.438961776304
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2009/Dec/04/t1259955185606htjzu5ua42i1/19ejg1259955133.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/04/t1259955185606htjzu5ua42i1/19ejg1259955133.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Dec/04/t1259955185606htjzu5ua42i1/2nbk31259955133.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/04/t1259955185606htjzu5ua42i1/2nbk31259955133.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Dec/04/t1259955185606htjzu5ua42i1/3uair1259955133.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/04/t1259955185606htjzu5ua42i1/3uair1259955133.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