Home » date » 2009 » May » 31 »

Opgave 10 - Sofie Loopmans - Eigen reeks

*Unverified author*
R Software Module: rwasp_exponentialsmoothing.wasp (opens new window with default values)
Title produced by software: Exponential Smoothing
Date of computation: Sun, 31 May 2009 02:52:16 -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/May/31/t12437599749irha7s02v18yeg.htm/, Retrieved Sun, 31 May 2009 10:52:54 +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/May/31/t12437599749irha7s02v18yeg.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 «
30,06 30,46 30,46 30,49 30,49 30,5 30,5 30,5 30,51 30,51 30,61 30,88 30,95 31,09 31,28 31,31 31,32 31,34 31,34 31,34 31,34 31,36 31,36 31,36 31,72 32,07 32,13 32,19 32,26 32,27 32,28 32,28 32,28 32,29 32,61 32,68 32,69 32,74 32,86 32,86 32,9 32,95 32,95 32,96 32,99 33 33,06 33,42 33,48 33,5 33,51 33,52 33,55 33,56 33,56 33,56 33,6 33,61 33,62 33,72 33,83 33,96 34,06 34,11 34,11 34,21 34,19 34,17 34,12 34,15 34,15 34,15
 
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
alpha1
beta0.601307369123789
gamma0


Interpolation Forecasts of Exponential Smoothing
tObservedFittedResiduals
330.4630.86-0.400000000000002
430.4930.6194770523505-0.129477052350488
530.4930.5716215466397-0.0816215466397097
630.530.522541909166-0.0225419091659695
730.530.5189872930704-0.0189872930703530
830.530.5075700938274-0.0075700938274359
930.5130.50301814062400.00698185937596207
1030.5130.517216384117-0.00721638411699033
1130.6130.5128771191690.0971228808309803
1230.8830.67127782312320.208722176876783
1330.9531.0667840061788-0.116784006178786
1431.0931.06656092266770.0234390773323163
1531.2831.22065501259310.0593449874069343
1631.3131.4463395908414-0.136339590841416
1731.3231.3943575901651-0.0743575901651461
1831.3431.3596458232486-0.0196458232485597
1931.3431.3678326449567-0.0278326449566961
2031.3431.351096670442-0.0110966704420292
2131.3431.3444241607325-0.00442416073249774
2231.3631.34176388028190.0182361197181393
2331.3631.3727293934526-0.0127293934526023
2431.3631.3650751153651-0.00507511536507721
2531.7231.36202341109690.357976588903096
2632.0731.93727737197810.132722628021870
2732.1332.3670844662572-0.237084466257159
2832.1932.2845238295920-0.0945238295919566
2932.2632.2876859543005-0.0276859543005088
3032.2732.3410381859584-0.0710381859583791
3132.2832.3083224012524-0.0283224012524315
3232.2832.3012919326681-0.0212919326680634
3332.2832.2884889366519-0.00848893665186523
3432.2932.28338447648710.00661552351292016
3532.6132.2973624395260.312637560473995
3632.6832.8053537085039-0.125353708503901
3732.6932.7999775998335-0.109977599833513
3832.7432.7438472586151-0.00384725861506752
3932.8632.79153387365890.068466126341093
4032.8632.9527030599632-0.0927030599631635
4132.932.8969600268670.00303997313300641
4232.9532.93878798511380.0112120148861976
4332.9532.9955298522876-0.0455298522876006
4432.9632.9681524165920-0.00815241659195465
4532.9932.97325030841900.0167496915809622
463333.0133220213972-0.0133220213972223
4733.0633.01531139175940.0446886082405555
4833.4233.10218298121040.317817018789619
4933.4833.6532886966415-0.173288696641535
5033.533.6090889263651-0.109088926365118
5133.5133.563492951052-0.0534929510519717
5233.5233.5413272453882-0.0213272453882354
5333.5533.53850301557320.0114969844268131
5433.5633.5754162370317-0.0154162370317223
5533.5633.5761463401004-0.0161463401003914
5633.5633.5664374268136-0.00643742681364756
5733.633.56256655463240.03743344536759
5833.6133.6250755611836-0.0150755611836360
5933.6233.6260105151502-0.00601051515023698
6033.7233.63239634809820.08760365190183
6133.8333.78507306954890.0449269304511049
6233.9633.92208796390130.0379120360987457
6334.0634.0748847505859-0.0148847505859209
6434.1134.1659344403710-0.0559344403710398
6534.1134.1823006491881-0.0723006491881151
6634.2134.13882573603890.071174263961133
6734.1934.2816233454507-0.0916233454506639
6834.1734.2065295526474-0.0365295526473943
6934.1234.1645640634497-0.0445640634497266
7034.1534.08776736369930.0622326363006991
7134.1534.1551883065069-0.00518830650691626
7234.1534.152068539571-0.00206853957103448


Extrapolation Forecasts of Exponential Smoothing
tForecast95% Lower Bound95% Upper Bound
7334.150824711483633.936451452789434.3651979701779
7434.151649422967333.746933075933634.556365770001
7534.152474134450933.530581154503434.7743671143985
7634.153298845934633.288397024415535.0182006674537
7734.154123557418233.022337020741835.2859100940946
7834.154948268901932.734159654898635.5757368829052
7934.155772980385532.425343461429735.8862024993414
8034.156597691869232.097128958494436.2160664252439
8134.157422403352831.750567959753736.5642768469519
8234.158247114836531.386563607865236.9299306218077
8334.159071826320131.005900801756537.3122428508838
8434.159896537803830.609269121327137.7105239542804
 
Charts produced by software:
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2009/May/31/t12437599749irha7s02v18yeg/1rea41243759931.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2009/May/31/t12437599749irha7s02v18yeg/1rea41243759931.ps (open in new window)


http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2009/May/31/t12437599749irha7s02v18yeg/207ml1243759931.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2009/May/31/t12437599749irha7s02v18yeg/207ml1243759931.ps (open in new window)


http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2009/May/31/t12437599749irha7s02v18yeg/30qkd1243759931.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2009/May/31/t12437599749irha7s02v18yeg/30qkd1243759931.ps (open in new window)


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