Home » date » 2010 » Aug » 19 »

*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 09:17:21 +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/t1282209525sdow2xutdrlvce6.htm/, Retrieved Thu, 19 Aug 2010 11:18:45 +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/t1282209525sdow2xutdrlvce6.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:
DeGroodtOlivierREEKSBStap27
 
Dataseries X:
» Textbox « » Textfile « » CSV «
80 79 78 76 74 73 74 76 77 77 78 80 90 90 89 82 78 76 74 78 81 82 88 99 117 113 106 100 97 96 100 104 104 111 117 118 140 147 134 126 116 114 120 122 117 119 132 134 154 152 132 130 123 129 124 128 128 129 141 138 155 160 142 133 131 140 134 134 134 136 145 137 152 168 160 157 147 161 159 164 163 158 175 163
 
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.635975324827265
beta0.008138384857576
gamma1


Interpolation Forecasts of Exponential Smoothing
tObservedFittedResiduals
139087.03659188034192.9634081196581
149089.27967877060.720321229399957
158988.93327932777320.0667206722267792
168282.0465513919437-0.046551391943737
177877.83754427705870.162455722941317
187675.17896803689320.821031963106776
197480.0268128753726-6.0268128753726
207877.73840371821230.261596281787732
218178.40895492391932.59104507608068
228279.78272217865512.21727782134488
238882.22192556186895.77807443813114
249988.080613956831410.9193860431686
25117106.51098670348110.4890132965191
26113112.8683161750760.131683824924238
27106112.051266821771-6.05126682177128
28100101.342386107546-1.34238610754639
299796.48860697053270.511393029467314
309694.39675341795861.60324658204138
3110097.358400724442.64159927555993
32104103.0260077373230.973992262677044
33104105.155273112518-1.15527311251789
34111104.1486947618596.85130523814149
35117110.9935087480066.00649125199371
36118119.032476809319-1.03247680931877
37140129.80668072412010.1933192758804
38147132.30568946904414.6943105309564
39134138.67479505276-4.67479505275992
40126130.738019838492-4.73801983849214
41116124.564502270107-8.56450227010698
42114117.216069249189-3.21606924918862
43120117.5837970920342.41620290796637
44122122.592901352030-0.592901352029642
45117123.034339844768-6.03433984476798
46119121.897918325330-2.89791832532987
47132122.2430042019159.75699579808528
48134130.1323251043023.86767489569758
49154148.1622161848215.83778381517891
50152149.5599851173602.44001488264047
51132141.051704134660-9.05170413465979
52130130.252528762407-0.252528762407167
53123125.506176271455-2.50617627145536
54129123.9564449022165.04355509778377
55124131.668920540651-7.66892054065073
56128129.158092712267-1.15809271226669
57128127.2456860156820.754313984317804
58129131.589972890176-2.58997289017583
59141136.7607565807124.23924341928804
60138138.991657257165-0.991657257165173
61155154.6177425273170.382257472682511
62160151.2502640861738.74973591382664
63142142.545403129008-0.545403129007838
64133140.377031698605-7.37703169860461
65131130.2603021887070.739697811293041
66140133.5209695393686.47903046063232
67134137.523961410038-3.52396141003754
68134140.046024962477-6.04602496247716
69134135.722575839689-1.72257583968891
70136137.262797692503-1.26279769250345
71145145.759083250348-0.759083250348198
72137142.876572122086-5.87657212208572
73152155.840405078971-3.8404050789712
74168152.75582450560215.2441754943977
75160144.75365933166715.2463406683333
76157150.1793534498876.82064655011268
77147152.157958840575-5.15795884057499
78161153.8378676691927.16213233080845
79159154.7182420934494.28175790655095
80164161.4111405799562.58885942004358
81163164.322482979171-1.32248297917127
82158166.45597137444-8.45597137443994
83175170.6951567000814.30484329991936
84163169.330711862381-6.33071186238058


Extrapolation Forecasts of Exponential Smoothing
tForecast95% Lower Bound95% Upper Bound
85182.905013837075171.820819075086193.989208599064
86189.388047230008176.221279840589202.554814619426
87171.79080264156.801244376908186.780360903092
88164.473179411447147.834813013414181.111545809480
89157.738351253270139.577528461572175.899174044969
90167.194945735493147.608364009266186.781527461721
91162.446317427679141.510751595773183.381883259585
92165.752169210966143.530259617282187.974078804650
93165.532138797572142.076077445583188.988200149562
94165.855675906723141.209679401325190.501672412121
95180.107416276005154.309454392476205.905378159534
96172.100826234940145.183871029814199.017781440066
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Aug/19/t1282209525sdow2xutdrlvce6/1b5an1282209437.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Aug/19/t1282209525sdow2xutdrlvce6/1b5an1282209437.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Aug/19/t1282209525sdow2xutdrlvce6/24eaq1282209437.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Aug/19/t1282209525sdow2xutdrlvce6/24eaq1282209437.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Aug/19/t1282209525sdow2xutdrlvce6/34eaq1282209437.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Aug/19/t1282209525sdow2xutdrlvce6/34eaq1282209437.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=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