Home » date » 2010 » Jun » 02 »

*Unverified author*
R Software Module: /rwasp_exponentialsmoothing.wasp (opens new window with default values)
Title produced by software: Exponential Smoothing
Date of computation: Wed, 02 Jun 2010 12:29:27 +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/Jun/02/t127548180920p72znewyigipt.htm/, Retrieved Wed, 02 Jun 2010 14:30:10 +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/Jun/02/t127548180920p72znewyigipt.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:
KDGP2W62
 
Dataseries X:
» Textbox « » Textfile « » CSV «
306 303 344 254 309 310 379 294 356 318 405 545 268 243 273 273 236 222 302 285 309 322 362 471 198 253 173 186 185 105 228 214 189 270 277 378 185 182 258 179 197 168 250 211 260 234 305 347 203 217 227 242 185 175 252 319 202 254 336 431 150 280 187 279 193 227 225 205 259 254 275 394 159 230 188 195 189 220 274
 
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'RServer@AstonUniversity' @ vre.aston.ac.uk


Estimated Parameters of Exponential Smoothing
ParameterValue
alpha0.215289717700249
beta0.032381255659449
gamma0.187381168803615


Interpolation Forecasts of Exponential Smoothing
tObservedFittedResiduals
13268293.967403205295-25.9674032052949
14243261.279066016922-18.2790660169215
15273287.52216433785-14.5221643378497
16273282.154029536538-9.15402953653762
17236240.052393908794-4.05239390879376
18222225.321974382947-3.32197438294742
19302331.62591223883-29.6259122388303
20285251.25291072260233.7470892773981
21309313.420014435399-4.42001443539868
22322276.64280803927445.3571919607256
23362362.153841458186-0.153841458186321
24471490.446318134576-19.4463181345757
25198237.556905757886-39.5569057578857
26253207.14475459958345.8552454004175
27173242.749178750529-69.749178750529
28186225.533027265585-39.5330272655852
29185185.187465645161-0.18746564516124
30105173.356597197516-68.356597197516
31228228.919913889412-0.919913889411617
32214180.48625537218633.5137446278141
33189220.432903705423-31.4329037054227
34270191.48028459707178.5197154029286
35277254.89582549068422.1041745093161
36378346.34201941393631.6579805860641
37185167.75060481695717.2493951830433
38182163.14461105354218.8553889464584
39258172.06550819789185.9344918021087
40179192.634343570042-13.6343435700416
41197166.78300833163630.2169916683642
42168152.74675228169415.2532477183061
43250242.9626707144087.03732928559191
44211200.51320122931310.486798770687
45260229.48416549191330.5158345080868
46234231.5340128017342.46598719826557
47305275.10336949746729.8966305025329
48347379.766922808021-32.7669228080214
49203178.91780500718424.0821949928156
50217177.13669908112739.8633009188732
51227202.58484713944524.4151528605552
52242196.24257084910845.7574291508921
53185189.642691850002-4.64269185000157
54175165.7313907429439.26860925705742
55252260.478030455908-8.47803045590757
56319214.338386057477104.661613942523
57202273.969829179295-71.9698291792946
58254250.9695357702263.03046422977351
59336304.6815724127831.3184275872205
60431411.22497025110119.775029748899
61150207.729195404114-57.7291954041145
62280191.14187644553388.8581235544666
63187227.712173791822-40.712173791822
64279210.73988492870468.2601150712957
65193201.106681466562-8.10668146656226
66227178.0466837277348.9533162722699
67225290.934832372585-65.9348323725854
68205246.610130541036-41.6101305410363
69259247.45853360637611.5414663936241
70254254.071138930979-0.0711389309789752
71275312.311437781-37.3114377809997
72394398.862204264107-4.86220426410745
73159188.910702268935-29.9107022689349
74230198.49577734957831.504222650422
75188203.293034542196-15.2930345421961
76195206.610537141597-11.6105371415968
77189172.66552783491716.3344721650835
78220163.92631391359956.0736860864014
79274251.89951483709422.1004851629063


Extrapolation Forecasts of Exponential Smoothing
tForecast95% Lower Bound95% Upper Bound
80231.040701285538203.79212270492258.289279866156
81249.081469270314216.3841820279281.778756512728
82251.865806467589214.621021325775289.110591609402
83304.523245620927258.040081787761351.006409454093
84406.817217799833343.993209779305469.641225820362
85189.373513740147150.07934087527228.667686605025
86216.730358229146169.517939860746263.942776597546
87208.114207807038158.498575390571257.729840223504
88216.359196790053161.365443341128271.352950238978
89187.825570647375135.064044334421240.587096960329
90181.062987484556126.105756282967236.020218686145
91250.825740951645167.49845593819334.153025965099
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Jun/02/t127548180920p72znewyigipt/1r9zx1275481763.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Jun/02/t127548180920p72znewyigipt/1r9zx1275481763.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Jun/02/t127548180920p72znewyigipt/22jzi1275481763.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Jun/02/t127548180920p72znewyigipt/22jzi1275481763.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Jun/02/t127548180920p72znewyigipt/32jzi1275481763.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Jun/02/t127548180920p72znewyigipt/32jzi1275481763.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