Home » date » 2010 » Dec » 18 »

opgave 10 deel 2

*Unverified author*
R Software Module: /rwasp_exponentialsmoothing.wasp (opens new window with default values)
Title produced by software: Exponential Smoothing
Date of computation: Sat, 18 Dec 2010 11:21:12 +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/Dec/18/t1292671163puau5zq94y9pjvb.htm/, Retrieved Sat, 18 Dec 2010 12:19:23 +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/2010/Dec/18/t1292671163puau5zq94y9pjvb.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:
KDGP2W102
 
Dataseries X:
» Textbox « » Textfile « » CSV «
68897 38683 44720 39525 45315 50380 40600 36279 42438 38064 31879 11379 70249 39253 47060 41697 38708 49267 39018 32228 40870 39383 34571 12066 70938 34077 45409 40809 37013 44953 37848 32745 43412 34931 33008 8620 68906 39556 50669 36432 40891 48428 36222 33425 39401 37967 34801 12657 69116 41519 51321 38529 41547 52073 38401 40898 40439 41888 37898 8771 68184 50530 47221 41756 45633 48138 39486 39341 41117 41629 29722 7054 56676 34870 35117 30169 30936 35699 33228 27733 33666 35429 27438 8170
 
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.422758923913050
beta0.477844184477007
gammaFALSE


Interpolation Forecasts of Exponential Smoothing
tObservedFittedResiduals
344720846936251
439525903.60314316598738621.396856834
5453152142.3328303147043172.6671696853
65038014026.588060662536353.4119393375
74060030371.800212500710228.1997874993
83627937738.5740196104-1459.57401961042
94243839869.38437850592568.61562149406
103806444222.0413286801-6158.04132868013
113187943641.4224318185-11762.4224318185
121137938315.3404237785-26936.3404237785
137024921132.861111941349116.1388880587
143925346024.3394358417-6771.33943584168
154706045920.98969285551139.01030714453
164169749391.9056625523-7694.9056625523
173870847573.7346669561-8865.7346669561
184926743469.59255071195797.40744928814
193901846735.5756687651-7717.57566876514
203222842728.9292775769-10500.9292775769
214087035424.27220491615445.72779508385
223938335961.31394391873421.68605608126
233457136333.8986752910-1762.89867529104
241206634158.5256828297-22092.5256828297
257093818925.646421214052012.353578786
263407745528.4322029733-11451.4322029733
274540942987.99924926532421.00075073470
284080946801.334489285-5992.33448928497
293701345847.3283493461-8834.32834934613
304495341907.19571378633045.80428621374
313784843604.7869032431-5756.78690324306
323274540418.0589357797-7673.05893577969
334341234871.15303039368540.84696960635
343493137904.1817449405-2973.18174494048
353300835468.9310238346-2460.93102383461
36862032753.0990701987-24133.0990701987
376890615999.967508699852906.0324913002
383955642503.5169980974-2947.51699809745
395066944799.04357200995869.95642799015
403643252008.0426043053-15576.0426043053
414089147003.9927319350-6112.99273193495
424842844765.62829248593662.37170751409
433622247399.7327090261-11177.7327090261
443342541502.0044273972-8077.00442739722
453940135283.47766446584117.52233553418
463796735052.08851339072914.91148660926
473480134901.1345968503-100.134596850323
481265733455.3145628964-20798.3145628964
496911619057.626540429550058.3734595705
504151944727.6725512194-3208.67255121942
515132147230.4062849694090.59371503098
523852953645.3226421855-15116.3226421855
534154748886.6516366273-7339.65163662735
545207345932.93343460696140.0665653931
553840149918.2590058089-11517.2590058089
564089844112.157805532-3214.15780553204
574043941166.9654162397-727.96541623972
584188839125.77464618122762.22535381879
593789839118.0983057955-1220.09830579548
60877137180.3835116219-28409.3835116219
616818418009.094003872750174.9059961273
625053042195.9920925928334.00790740797
634722150377.8541793261-3156.85417932607
644175653064.1265291758-11308.1265291758
654563350019.9883947382-4386.98839473825
664813849015.594952092-877.594952092048
673948649317.5434094924-9831.5434094924
683934143848.0317232249-4507.03172322489
694111739719.0263495291397.97365047099
704162938368.82339510523260.17660489482
712972238464.481066189-8742.48106618904
72705431719.8142019803-24665.8142019803
735667613260.603665418843415.3963345812
743487032353.80225816392516.19774183613
753511734664.804050695452.195949305002
763016936194.580078486-6025.58007848597
773093633768.5736183887-2832.5736183887
783569932120.22274147873578.77725852134
793322833905.2868103312-677.286810331163
802773333754.2411452307-6021.24114523068
813366630127.62275149843538.37724850156
823542931257.21616822044171.78383177962
832743833497.3419922664-6059.34199226636
84817030188.1028656064-22018.1028656064


Extrapolation Forecasts of Exponential Smoothing
tForecast95% Lower Bound95% Upper Bound
8515684.2145018833-20477.293587426751845.7225911932
8610488.6756122307-32150.324837059653127.676061521
875293.13672257817-46783.362078336957369.6355234932
8897.597832925625-63902.523079056764097.718744908
89-5097.94105672692-83052.891590918672857.0094774648
90-10293.4799463795-103896.72209533183309.7622025718
91-15489.018836032-126198.19671249895220.1590404335
92-20684.5577256845-149791.367747329108422.252295960
93-25880.0966153371-174555.698614305122795.505383631
94-31075.6355049896-200400.322065361138249.051055381
95-36271.1743946422-227254.266961278154711.918171993
96-41466.7132842947-255060.345768303172126.919199714
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Dec/18/t1292671163puau5zq94y9pjvb/1piev1292671268.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/18/t1292671163puau5zq94y9pjvb/1piev1292671268.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/18/t1292671163puau5zq94y9pjvb/2hseg1292671268.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/18/t1292671163puau5zq94y9pjvb/2hseg1292671268.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/18/t1292671163puau5zq94y9pjvb/3hseg1292671268.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/18/t1292671163puau5zq94y9pjvb/3hseg1292671268.ps (open in new window)


 
Parameters (Session):
par1 = 12 ; par2 = Double ; par3 = multiplicative ;
 
Parameters (R input):
par1 = 12 ; par2 = Double ; 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