Home » date » 2009 » Jun » 05 »

exponential smoothing - sigaretten - caroline thys

*Unverified author*
R Software Module: rwasp_exponentialsmoothing.wasp (opens new window with default values)
Title produced by software: Exponential Smoothing
Date of computation: Fri, 05 Jun 2009 02:29:38 -0600
 
Cite this page as follows:
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL http://www.freestatistics.org/blog/date/2009/Jun/05/t124419069619ayydqkrf0g03b.htm/, Retrieved Fri, 05 Jun 2009 10:31:40 +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/2009/Jun/05/t124419069619ayydqkrf0g03b.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 «
106.07 106.07 106.07 106.07 106.07 106.2 107.5 108.31 108.53 108.61 108.62 108.62 108.62 108.62 110.1 110.74 110.77 110.77 110.78 110.78 110.78 110.84 110.84 110.84 110.84 110.84 111.01 112.66 114.04 114.16 114.2 114.2 114.23 114.23 114.23 114.23 114.23 114.23 115.97 116.96 117.08 117.08 117.08 117.63 119.12 119.47 119.5 119.52 119.49 119.49 119.5 119.5 119.56 122.35 122.92 122.92 123.04 123.04 123.04 123.06 123.33 128.21 129.57 129.79 131.66 135.01 136.01 136.31 136.37 136.4 136.4 136.4 137.34 142.18 143.79 144.08 144.08 144.09 144.09 144.11 144.11 144.15 144.15 144.16 144.2 144.38 144.38 144.28 144.46 144.53 144.53 145.34 147.98 150.42 150.53 150.64
 
Output produced by software:


Summary of computational transaction
Raw Inputview raw input (R code)
Raw Outputview raw output of R engine
Computing time1 seconds
R Server'Gwilym Jenkins' @ 72.249.127.135


Estimated Parameters of Exponential Smoothing
ParameterValue
alpha1
beta0.0252584287655884
gamma0.160169143914703


Interpolation Forecasts of Exponential Smoothing
tObservedFittedResiduals
13108.62106.5011591880342.11884081196575
14108.62108.716653787850-0.0966537878498599
15110.1110.237129131701-0.137129131701201
16110.74110.883665465296-0.143665465296408
17110.77110.911286701375-0.141286701375165
18110.77110.908134687960-0.138134687959607
19110.78110.7658956227840.0141043772162561
20110.78111.697501877191-0.917501877190944
21110.78111.022660554717-0.242660554716934
22110.84110.7881979970480.0518020029519022
23110.84110.7515897675830.0884102324170897
24110.84110.7479895378070.092010462192789
25110.84110.8094802441790.0305197558211461
26110.84110.897751125257-0.0577511252572123
27111.01112.419209089240-1.40920908924043
28112.66111.7236146818440.93638531815597
29114.04112.7885163037001.25148369630018
30114.16114.170543482161-0.0105434821607844
31114.2114.1515271703680.0484728296323169
32114.2115.114001517882-0.914001517882028
33114.23114.439248608984-0.209248608984282
34114.23114.235629984567-0.00562998456663877
35114.23114.1375711133360.0924288866641518
36114.23114.1340723884520.0959276115478076
37114.23114.1956620358620.0343379641382313
38114.23114.284029358883-0.0540293588829286
39115.97115.8055813288370.164418671162991
40116.96116.7197342861300.240265713869704
41117.08117.107053020549-0.027053020548891
42117.08117.196786370423-0.116786370423114
43117.08117.0550865302050.0249134697949813
44117.63117.976965805307-0.34696580530715
45119.12117.8665353275631.25346467243699
46119.47119.1598625423690.310137457631356
47119.5119.4197794605830.0802205394169135
48119.52119.4459723720300.0740276279698548
49119.49119.527008860265-0.0370088602645495
50119.49119.583574074604-0.093574074603879
51119.5121.104127207173-1.60412720717285
52119.5120.243609474380-0.743609474379525
53119.56119.616077067442-0.0560770674415068
54122.35119.6450773154952.70492268450519
55122.92122.3646494124380.555350587562174
56122.92123.869926695694-0.94992669569369
57123.04123.194266373251-0.154266373251303
58123.04123.082036513718-0.0420365137183012
59123.04122.9830580707640.056941929235677
60123.06122.9786630010940.0813369989056554
61123.33123.0598841125540.270115887446124
62128.21123.4242068154554.78579318454462
63129.57129.948005098361-0.378005098360745
64129.79130.468457283511-0.678457283510738
65131.66130.0625705185451.59742948145532
66135.01131.9433357439773.06666425602324
67136.01135.2320448646350.777955135364493
68136.31137.172944789005-0.8629447890049
69136.37136.799481492857-0.429481492856524
70136.4136.620300131830-0.220300131829788
71136.4136.546819029976-0.1468190299762
72136.4136.537277278633-0.137277278632808
73137.34136.5929765369360.747023463064039
74142.18137.6393451758644.540654824136
75143.79144.116951648955-0.326951648955259
76144.08144.888693364020-0.808693364020257
77144.08144.549517040292-0.469517040292004
78144.09144.508074444242-0.418074444242222
79144.09144.368764540674-0.27876454067362
80144.11145.282973386381-1.17297338638062
81144.11144.62167925499-0.511679254990128
82144.15144.380421707644-0.230421707643842
83144.15144.316684950689-0.166684950688591
84144.16144.306641417402-0.146641417402009
85144.2144.372104152273-0.172104152273107
86144.38144.495257071803-0.115257071802631
87144.38146.195262525931-1.81526252593147
88144.28145.319411846729-1.03941184672937
89144.46144.584407936641-0.124407936640665
90144.53144.731682254302-0.201682254301829
91144.53144.657838077448-0.127838077448274
92145.34145.575859088475-0.235859088475479
93147.98145.7282349918242.25176500817614
94150.42148.1967777045462.22322229545358
95150.53150.595016139859-0.0650161398594946
96150.64150.697540600989-0.0575406009889434


Extrapolation Forecasts of Exponential Smoothing
tForecast95% Lower Bound95% Upper Bound
97150.865253882484148.725181116073153.005326648896
98151.178007764969148.113026924141154.242988605796
99153.013678314120149.212568977828156.814787650412
100154.019348863271149.575394633073158.463303093468
101154.416269412422149.386275132633159.446263692211
102154.783606628240149.205917518094160.361295738385
103155.012193844057148.914334127451161.110053560664
104156.162031059875149.564568043247162.759494076503
105156.660201609026149.578935121621163.741468096431
106156.930038824844149.377344774892164.482732874795
107157.101959373995149.087664697949165.116254050040
108157.268046589812148.800025914841165.736067264783
 
Charts produced by software:
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2009/Jun/05/t124419069619ayydqkrf0g03b/14znh1244190576.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2009/Jun/05/t124419069619ayydqkrf0g03b/14znh1244190576.ps (open in new window)


http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2009/Jun/05/t124419069619ayydqkrf0g03b/2900t1244190576.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2009/Jun/05/t124419069619ayydqkrf0g03b/2900t1244190576.ps (open in new window)


http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2009/Jun/05/t124419069619ayydqkrf0g03b/3li0j1244190576.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2009/Jun/05/t124419069619ayydqkrf0g03b/3li0j1244190576.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