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 07:29:24 +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/t1275463925j4jw2fi9kpfmuzn.htm/, Retrieved Wed, 02 Jun 2010 09:32: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/t1275463925j4jw2fi9kpfmuzn.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:
eline.horemans@student.kdg.be
 
IsPrivate?
No (this computation is public)
 
User-defined keywords:
KDGP2W62
 
Dataseries X:
» Textbox « » Textfile « » CSV «
464 675 703 887 1139 1077 1318 1260 1120 963 996 960 530 883 894 1045 1199 1287 1565 1577 1076 918 1008 1063 544 635 804 980 1018 1064 1404 1286 1104 999 996 1015 615 722 832 977 1270 1437 1520 1708 1151 934 1159 1209 699 830 996 1124 1458 1270 1753 2258 1208 1241 1265 1828 809 997 1164 1205 1538 1513 1378 2083 1357 1536 1526 1376 779 1005 1193 1522 1539 1546 2116 2326 1596 1356 1553 1613 814 1150 1225 1691 1759 1754 2100 2062 2012 1897 1964 2186 966 1549 1538 1612 2078 2137 2907 2249 1883 1739 1828 1868 1138 1430 1809 1763 2200 2067 2503 2141 2103 1972 2181 2344 970 1199 1718 1683 2025 2051 2439 2353 2230 1852 2147 2286 1007 1665 1642 1518 1831 2207 2822 2393 2306 1785 2047 2171 1212 1335 2011 1860 1954 2152 2835 2224 2182 1992 2389 2724 891 1247 2017 2257 2255 2255 3057 3330 1896 2096 2374 2535 1041 1728 2201 2455 2204 2660 3670 2665 etc...
 
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'Gwilym Jenkins' @ 72.249.127.135


Estimated Parameters of Exponential Smoothing
ParameterValue
alpha0.128930926063059
beta0
gamma0.318961787795789


Interpolation Forecasts of Exponential Smoothing
tObservedFittedResiduals
13530488.83695900046341.163040999537
14883814.75523893239968.2447610676013
15894834.61852403814959.3814759618515
161045999.13603200943545.8639679905651
1711991167.5174428106431.4825571893605
1812871265.7678925140221.2321074859849
1915651471.5441169062293.455883093782
2015771416.67395034438160.326049655620
2110761269.32628721628-193.326287216280
229181065.59758763115-147.597587631153
2310081084.10736657534-76.1073665753388
2410631034.9518793466628.0481206533357
25544581.982552876668-37.9825528766681
26635950.01704297118-315.01704297118
27804917.750504008918-113.750504008918
289801063.42543153307-83.425431533069
2910181216.09603740948-198.096037409481
3010641282.55780968998-218.557809689982
3114041474.02347356884-70.0234735688375
3212861417.91458147561-131.914581475614
3311041148.84690724577-44.8469072457747
34999983.31927443460315.6807255653965
359961041.62335100716-45.6233510071575
3610151025.6617778338-10.6617778338000
37615559.41124784027655.5887521597242
38722858.653333515306-136.653333515306
39832906.056318391442-74.0563183914425
409771069.55862086221-92.55862086221
4112701191.2360260260578.763973973949
4214371290.50915889255146.490841107447
4315201593.93855847723-73.9385584772338
4417081512.02680738275195.973192617247
4511511278.88506606664-127.885066066642
469341101.55325635512-167.553256355115
4711591121.7000205159537.2999794840518
4812091125.0045063484183.9954936515919
49699638.41288507031560.5871149296852
50830909.400985151356-79.4009851513558
51996990.0938507714445.90614922855627
5211241179.04487730169-55.0448773016915
5314581375.8299184303182.1700815696906
5412701506.27911116513-236.279111165128
5517531718.313904188634.6860958114012
5622581723.10131469524534.898685304756
5712081397.79915781362-189.79915781362
5812411178.6847664400362.315233559967
5912651298.32903611964-33.3290361196437
6018281305.30176605923522.698233940772
61809774.56118204673334.4388179532666
629971040.77010167051-43.7701016705096
6311641168.75073612202-4.75073612201572
6412051367.6983549032-162.698354903199
6515381626.18580375515-88.1858037551515
6615131647.32610180479-134.326101804787
6713781994.8473981759-616.847398175902
6820832061.2178209405321.7821790594703
6913571428.82192211012-71.8219221101172
7015361284.72546884146251.274531158535
7115261409.0793621541116.920637845899
7213761598.65940088826-222.659400888261
73779810.73714273177-31.7371427317696
7410051051.93266238057-46.9326623805705
7511931193.37607240147-0.376072401467354
7615221351.58581532867170.414184671327
7715391689.45800268104-150.458002681038
7815461689.68549575826-143.685495758261
7921161905.13461397824210.865386021764
8023262288.7565481025137.2434518974892
8115961559.5920370508036.4079629492023
8213561510.71249582125-154.712495821247
8315531548.271436262054.72856373794889
8416131632.16622149008-19.1662214900787
85814866.034135880236-52.0341358802364
8611501118.2730043574831.7269956425243
8712251295.90142116044-70.9014211604406
8816911506.94089288937184.059107110634
8917591773.46513372946-14.4651337294576
9017541793.43097722004-39.4309772200411
9121002150.52505344624-50.5250534462384
9220622474.58202317727-412.58202317727
9320121649.13461538531362.865384614687
9418971579.57425173296317.42574826704
9519641733.10680944281230.893190557190
9621861848.41951486649337.580485133513
97966990.716000674308-24.7160006743081
9815491316.00081055352232.999189446478
9915381516.7255264078421.2744735921622
10016121865.30779150913-253.307791509130
10120782048.0874998809029.9125001190969
10221372067.2207979544169.7792020455922
10329072493.16925096456413.830749035440
10422492815.31344148217-566.313441482172
10518832074.7657014799-191.765701479898
10617391898.77284610264-159.772846102645
10718281973.17415285422-145.174152854216
10818682074.50887478492-206.508874784916
10911381014.42752648855123.572473511449
11014301448.76169452102-18.7616945210216
11118091560.78133262785248.218667372145
11217631872.46637985906-109.466379859062
11322002167.8289886827732.1710113172339
11420672198.99757413641-131.997574136406
11525032712.50610912219-209.506109122188
11621412677.56580949333-536.565809493326
11721032039.0539358569663.9460641430412
11819721900.5402223616171.4597776383923
11921812012.03876025336168.961239746642
12023442141.73511193062202.264888069379
1219701141.04354334107-171.043543341066
12211991516.72816114097-317.728161140968
12317181667.2649051731950.7350948268104
12416831855.10955042207-172.109550422071
12520252182.64731643919-157.647316439192
12620512143.70912748383-92.709127483828
12724392637.04671442342-198.046714423419
12823532509.46343944927-156.463439449273
12922302081.67868386108148.321316138916
13018521953.33939339838-101.339393398375
13121472069.7932570340777.2067429659337
13222862196.1855440393889.8144559606185
13310071084.64792832794-77.647928327937
13416651430.19404726694234.805952733061
13516421769.23922025062-127.239220250619
13615181875.82278453689-357.822784536888
13718312191.54539780048-360.545397800477
13822072144.1852889921162.8147110078899
13928222637.89742440655184.102575593454
14023932566.47025484265-173.470254842647
14123062207.3178541475798.6821458524314
14217851994.72252902756-209.722529027564
14320472151.56574794136-104.565747941355
14421712259.77921774676-88.7792177467613
14512121070.26508143285141.734918567153
14613351544.13335047298-209.133350472983
14720111723.90986670660287.090133293397
14818601818.5252811857041.4747188142951
14919542201.59379662456-247.593796624557
15021522292.73539533376-140.735395333764
15128352817.7963195002017.2036804998047
15222242616.82823281669-392.828232816688
15321822297.14668489135-115.146684891355
15419921965.4977454508326.5022545491663
15523892188.10276913204200.897230867962
15627242345.61843415762378.381565842381
1578911193.66533165030-302.665331650297
15812471519.99089775425-272.990897754245
15920171833.60178236905183.398217630952
16022571846.38991421299410.610085787007
16122552205.6598829931349.3401170068732
16222552371.89557184749-116.895571847493
16330572974.9589710768182.041028923195
16433302647.35367654457682.646323455434
16518962520.14220101208-624.142201012083
16620962137.97226036438-41.9722603643763
16723742419.71801410648-45.7180141064846
16825352603.13644850766-68.1364485076638
16910411148.50094503263-107.50094503263
17017281528.24102368985199.758976310149
17122012076.81793642787124.182063572127
17224552145.67557931209309.324420687911
17322042408.11543436073-204.115434360731
17426602502.41008370423157.589916295772
17536703252.23288577992417.767114220076
17626653109.720088842-444.720088841997
17726392442.44363393001196.556366069986
17822262314.42316529856-88.423165298559
17925862612.65435638816-26.6543563881555
18026842806.99681258423-122.996812584234
18111851211.47427616192-26.4742761619227
18217491730.0709769897818.9290230102185
18324592271.6238317361187.376168263900
18426182405.78894534087212.211054659133
18525852517.2877721546567.7122278453548
18633102764.81400431412545.185995685879
18739233717.08072903676205.919270963237


Extrapolation Forecasts of Exponential Smoothing
tForecast95% Lower Bound95% Upper Bound
1883262.851771364763097.721529041863427.98201368767
1892779.903028373352608.905649841842950.90040690486
1902522.426002142712346.030730136782698.82127414865
1912882.932062192482693.719101965763072.14502241921
1923070.847781003582870.962648679853270.73291332731
1931340.563108470301166.828380260701514.29783667991
1941936.536834646341739.119310279892133.95435901279
1952587.659677581352357.764237526112817.55511763658
1962714.660208545322473.435654124712955.88476296592
1972761.519808001672512.879398273703010.16021772965
1983159.455099884352884.328342920683434.58185684802
1993991.417302306353706.13597459554276.69863001720
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Jun/02/t1275463925j4jw2fi9kpfmuzn/1ceuj1275463761.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Jun/02/t1275463925j4jw2fi9kpfmuzn/1ceuj1275463761.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Jun/02/t1275463925j4jw2fi9kpfmuzn/2ceuj1275463761.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Jun/02/t1275463925j4jw2fi9kpfmuzn/2ceuj1275463761.ps (open in new window)


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