Free Statistics

of Irreproducible Research!

Author's title

Author*Unverified author*
R Software ModulePatrick.Wessarwasp_demand_forecasting_croston.wasp
Title produced by softwareCroston Forecasting
Date of computationThu, 13 May 2010 11:25:16 +0000
Cite this page as followsStatistical Computations at FreeStatistics.org, Office for Research Development and Education, URL https://freestatistics.org/blog/index.php?v=date/2010/May/13/t1273749990jcwwlesjnpixvsz.htm/, Retrieved Sun, 05 May 2024 21:50:16 +0000
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL https://freestatistics.org/blog/index.php?pk=75866, Retrieved Sun, 05 May 2024 21:50:16 +0000
QR Codes:

Original text written by user:
IsPrivate?No (this computation is public)
User-defined keywordsB11A,steven,coomans,croston,thesis
Estimated Impact187
Family? (F = Feedback message, R = changed R code, M = changed R Module, P = changed Parameters, D = changed Data)
-       [Croston Forecasting] [B11A,steven,cooma...] [2010-05-13 11:25:16] [d41d8cd98f00b204e9800998ecf8427e] [Current]
Feedback Forum

Post a new message
Dataseries X:
62
30
31
50
33
12
20
30
21,5
23
13,5
0,5
12
10
70,5
30
20,5
12
20
45
11,505

10
5,5
27,5
0,5
7
0
2,5
0
0
6,025
1
0
0
0
0
2
0
6
20
0
0
0
7
35
0
0
0
1




\begin{tabular}{lllllllll}
\hline
Summary of computational transaction \tabularnewline
Raw Input & view raw input (R code)  \tabularnewline
Raw Output & view raw output of R engine  \tabularnewline
Computing time & 4 seconds \tabularnewline
R Server & wessa.org @ wessa.org \tabularnewline
R Framework error message & 
Warning: there are blank lines in the 'Data' field.
Please, use NA for missing data - blank lines are simply
 deleted and are NOT treated as missing values.
\tabularnewline \hline \end{tabular} %Source: https://freestatistics.org/blog/index.php?pk=75866&T=0

[TABLE]
[ROW][C]Summary of computational transaction[/C][/ROW]
[ROW][C]Raw Input[/C][C]view raw input (R code) [/C][/ROW]
[ROW][C]Raw Output[/C][C]view raw output of R engine [/C][/ROW]
[ROW][C]Computing time[/C][C]4 seconds[/C][/ROW]
[ROW][C]R Server[/C][C]wessa.org @ wessa.org[/C][/ROW]
[ROW][C]R Framework error message[/C][C]
Warning: there are blank lines in the 'Data' field.
Please, use NA for missing data - blank lines are simply
 deleted and are NOT treated as missing values.
[/C][/ROW] [/TABLE] Source: https://freestatistics.org/blog/index.php?pk=75866&T=0

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=75866&T=0

As an alternative you can also use a QR Code:  

The GUIDs for individual cells are displayed in the table below:

Summary of computational transaction
Raw Inputview raw input (R code)
Raw Outputview raw output of R engine
Computing time4 seconds
R Serverwessa.org @ wessa.org
R Framework error message
Warning: there are blank lines in the 'Data' field.
Please, use NA for missing data - blank lines are simply
 deleted and are NOT treated as missing values.







Demand Forecast
PointForecast95% LB80% LB80% UB95% UB
5014.3609042135616-17.7837243965962-6.6573386950522535.379147122175446.5055328237194
5114.3609042135616-17.9440477283594-6.7621684870459435.483976914169146.6658561554826
5214.3609042135616-18.1035793254488-6.8664805915623435.588289018685546.8253877525719
5314.3609042135616-18.2623308029037-6.9702826032674535.692091030390646.9841392300268
5414.3609042135616-18.4203134945159-7.0735819329294435.795390360052647.1421219216391
5514.3609042135616-18.5775384622727-7.1763858135929635.898194240716147.2993468893959
5614.3609042135616-18.7340165053958-7.2787013064895136.000509733612747.455824932519
5714.3609042135616-18.8897581689974-7.3805353066974236.102343733820647.6115665961206
5814.3609042135616-19.0447737523737-7.4818945485644736.203702975687647.7665821794968
5914.3609042135616-19.1990733169527-7.5827856109048236.30459403802847.9208817440758

\begin{tabular}{lllllllll}
\hline
Demand Forecast \tabularnewline
Point & Forecast & 95% LB & 80% LB & 80% UB & 95% UB \tabularnewline
50 & 14.3609042135616 & -17.7837243965962 & -6.65733869505225 & 35.3791471221754 & 46.5055328237194 \tabularnewline
51 & 14.3609042135616 & -17.9440477283594 & -6.76216848704594 & 35.4839769141691 & 46.6658561554826 \tabularnewline
52 & 14.3609042135616 & -18.1035793254488 & -6.86648059156234 & 35.5882890186855 & 46.8253877525719 \tabularnewline
53 & 14.3609042135616 & -18.2623308029037 & -6.97028260326745 & 35.6920910303906 & 46.9841392300268 \tabularnewline
54 & 14.3609042135616 & -18.4203134945159 & -7.07358193292944 & 35.7953903600526 & 47.1421219216391 \tabularnewline
55 & 14.3609042135616 & -18.5775384622727 & -7.17638581359296 & 35.8981942407161 & 47.2993468893959 \tabularnewline
56 & 14.3609042135616 & -18.7340165053958 & -7.27870130648951 & 36.0005097336127 & 47.455824932519 \tabularnewline
57 & 14.3609042135616 & -18.8897581689974 & -7.38053530669742 & 36.1023437338206 & 47.6115665961206 \tabularnewline
58 & 14.3609042135616 & -19.0447737523737 & -7.48189454856447 & 36.2037029756876 & 47.7665821794968 \tabularnewline
59 & 14.3609042135616 & -19.1990733169527 & -7.58278561090482 & 36.304594038028 & 47.9208817440758 \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=75866&T=1

[TABLE]
[ROW][C]Demand Forecast[/C][/ROW]
[ROW][C]Point[/C][C]Forecast[/C][C]95% LB[/C][C]80% LB[/C][C]80% UB[/C][C]95% UB[/C][/ROW]
[ROW][C]50[/C][C]14.3609042135616[/C][C]-17.7837243965962[/C][C]-6.65733869505225[/C][C]35.3791471221754[/C][C]46.5055328237194[/C][/ROW]
[ROW][C]51[/C][C]14.3609042135616[/C][C]-17.9440477283594[/C][C]-6.76216848704594[/C][C]35.4839769141691[/C][C]46.6658561554826[/C][/ROW]
[ROW][C]52[/C][C]14.3609042135616[/C][C]-18.1035793254488[/C][C]-6.86648059156234[/C][C]35.5882890186855[/C][C]46.8253877525719[/C][/ROW]
[ROW][C]53[/C][C]14.3609042135616[/C][C]-18.2623308029037[/C][C]-6.97028260326745[/C][C]35.6920910303906[/C][C]46.9841392300268[/C][/ROW]
[ROW][C]54[/C][C]14.3609042135616[/C][C]-18.4203134945159[/C][C]-7.07358193292944[/C][C]35.7953903600526[/C][C]47.1421219216391[/C][/ROW]
[ROW][C]55[/C][C]14.3609042135616[/C][C]-18.5775384622727[/C][C]-7.17638581359296[/C][C]35.8981942407161[/C][C]47.2993468893959[/C][/ROW]
[ROW][C]56[/C][C]14.3609042135616[/C][C]-18.7340165053958[/C][C]-7.27870130648951[/C][C]36.0005097336127[/C][C]47.455824932519[/C][/ROW]
[ROW][C]57[/C][C]14.3609042135616[/C][C]-18.8897581689974[/C][C]-7.38053530669742[/C][C]36.1023437338206[/C][C]47.6115665961206[/C][/ROW]
[ROW][C]58[/C][C]14.3609042135616[/C][C]-19.0447737523737[/C][C]-7.48189454856447[/C][C]36.2037029756876[/C][C]47.7665821794968[/C][/ROW]
[ROW][C]59[/C][C]14.3609042135616[/C][C]-19.1990733169527[/C][C]-7.58278561090482[/C][C]36.304594038028[/C][C]47.9208817440758[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=75866&T=1

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=75866&T=1

As an alternative you can also use a QR Code:  

The GUIDs for individual cells are displayed in the table below:

Demand Forecast
PointForecast95% LB80% LB80% UB95% UB
5014.3609042135616-17.7837243965962-6.6573386950522535.379147122175446.5055328237194
5114.3609042135616-17.9440477283594-6.7621684870459435.483976914169146.6658561554826
5214.3609042135616-18.1035793254488-6.8664805915623435.588289018685546.8253877525719
5314.3609042135616-18.2623308029037-6.9702826032674535.692091030390646.9841392300268
5414.3609042135616-18.4203134945159-7.0735819329294435.795390360052647.1421219216391
5514.3609042135616-18.5775384622727-7.1763858135929635.898194240716147.2993468893959
5614.3609042135616-18.7340165053958-7.2787013064895136.000509733612747.455824932519
5714.3609042135616-18.8897581689974-7.3805353066974236.102343733820647.6115665961206
5814.3609042135616-19.0447737523737-7.4818945485644736.203702975687647.7665821794968
5914.3609042135616-19.1990733169527-7.5827856109048236.30459403802847.9208817440758







Actuals and Interpolation
TimeActualForecast
162NA
23062
33158.8
45056.02
53355.418
61253.1762
72049.05858
83046.152722
921.544.5374498
102342.23370482
1113.540.310334338
120.537.6293009042
131233.91637081378
141031.724733732402
1570.529.5522603591618
163033.6470343232456
1720.533.2823308909211
181232.0040978018290
192030.0036880216461
204529.0033192194815
2111.50530.6029872975333
221028.69318856778
235.526.823869711002
2427.524.6914827399018
250.524.9723344659116
26722.5251010193204
27020.9725909173884
282.520.9725909173884
29017.3866652960451
30017.3866652960451
316.02517.3866652960451
32113.8103090256470
33012.7944240910199
34012.7944240910199
35012.7944240910199
36012.7944240910199
37212.7944240910199
3809.00384849281212
3969.00384849281212
40208.2854312890366
4109.0156435359206
4209.0156435359206
4309.0156435359206
4479.0156435359206
45357.43944706314875
4609.00587005590655
4709.00587005590655
4809.00587005590655
4919.00587005590655

\begin{tabular}{lllllllll}
\hline
Actuals and Interpolation \tabularnewline
Time & Actual & Forecast \tabularnewline
1 & 62 & NA \tabularnewline
2 & 30 & 62 \tabularnewline
3 & 31 & 58.8 \tabularnewline
4 & 50 & 56.02 \tabularnewline
5 & 33 & 55.418 \tabularnewline
6 & 12 & 53.1762 \tabularnewline
7 & 20 & 49.05858 \tabularnewline
8 & 30 & 46.152722 \tabularnewline
9 & 21.5 & 44.5374498 \tabularnewline
10 & 23 & 42.23370482 \tabularnewline
11 & 13.5 & 40.310334338 \tabularnewline
12 & 0.5 & 37.6293009042 \tabularnewline
13 & 12 & 33.91637081378 \tabularnewline
14 & 10 & 31.724733732402 \tabularnewline
15 & 70.5 & 29.5522603591618 \tabularnewline
16 & 30 & 33.6470343232456 \tabularnewline
17 & 20.5 & 33.2823308909211 \tabularnewline
18 & 12 & 32.0040978018290 \tabularnewline
19 & 20 & 30.0036880216461 \tabularnewline
20 & 45 & 29.0033192194815 \tabularnewline
21 & 11.505 & 30.6029872975333 \tabularnewline
22 & 10 & 28.69318856778 \tabularnewline
23 & 5.5 & 26.823869711002 \tabularnewline
24 & 27.5 & 24.6914827399018 \tabularnewline
25 & 0.5 & 24.9723344659116 \tabularnewline
26 & 7 & 22.5251010193204 \tabularnewline
27 & 0 & 20.9725909173884 \tabularnewline
28 & 2.5 & 20.9725909173884 \tabularnewline
29 & 0 & 17.3866652960451 \tabularnewline
30 & 0 & 17.3866652960451 \tabularnewline
31 & 6.025 & 17.3866652960451 \tabularnewline
32 & 1 & 13.8103090256470 \tabularnewline
33 & 0 & 12.7944240910199 \tabularnewline
34 & 0 & 12.7944240910199 \tabularnewline
35 & 0 & 12.7944240910199 \tabularnewline
36 & 0 & 12.7944240910199 \tabularnewline
37 & 2 & 12.7944240910199 \tabularnewline
38 & 0 & 9.00384849281212 \tabularnewline
39 & 6 & 9.00384849281212 \tabularnewline
40 & 20 & 8.2854312890366 \tabularnewline
41 & 0 & 9.0156435359206 \tabularnewline
42 & 0 & 9.0156435359206 \tabularnewline
43 & 0 & 9.0156435359206 \tabularnewline
44 & 7 & 9.0156435359206 \tabularnewline
45 & 35 & 7.43944706314875 \tabularnewline
46 & 0 & 9.00587005590655 \tabularnewline
47 & 0 & 9.00587005590655 \tabularnewline
48 & 0 & 9.00587005590655 \tabularnewline
49 & 1 & 9.00587005590655 \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=75866&T=2

[TABLE]
[ROW][C]Actuals and Interpolation[/C][/ROW]
[ROW][C]Time[/C][C]Actual[/C][C]Forecast[/C][/ROW]
[ROW][C]1[/C][C]62[/C][C]NA[/C][/ROW]
[ROW][C]2[/C][C]30[/C][C]62[/C][/ROW]
[ROW][C]3[/C][C]31[/C][C]58.8[/C][/ROW]
[ROW][C]4[/C][C]50[/C][C]56.02[/C][/ROW]
[ROW][C]5[/C][C]33[/C][C]55.418[/C][/ROW]
[ROW][C]6[/C][C]12[/C][C]53.1762[/C][/ROW]
[ROW][C]7[/C][C]20[/C][C]49.05858[/C][/ROW]
[ROW][C]8[/C][C]30[/C][C]46.152722[/C][/ROW]
[ROW][C]9[/C][C]21.5[/C][C]44.5374498[/C][/ROW]
[ROW][C]10[/C][C]23[/C][C]42.23370482[/C][/ROW]
[ROW][C]11[/C][C]13.5[/C][C]40.310334338[/C][/ROW]
[ROW][C]12[/C][C]0.5[/C][C]37.6293009042[/C][/ROW]
[ROW][C]13[/C][C]12[/C][C]33.91637081378[/C][/ROW]
[ROW][C]14[/C][C]10[/C][C]31.724733732402[/C][/ROW]
[ROW][C]15[/C][C]70.5[/C][C]29.5522603591618[/C][/ROW]
[ROW][C]16[/C][C]30[/C][C]33.6470343232456[/C][/ROW]
[ROW][C]17[/C][C]20.5[/C][C]33.2823308909211[/C][/ROW]
[ROW][C]18[/C][C]12[/C][C]32.0040978018290[/C][/ROW]
[ROW][C]19[/C][C]20[/C][C]30.0036880216461[/C][/ROW]
[ROW][C]20[/C][C]45[/C][C]29.0033192194815[/C][/ROW]
[ROW][C]21[/C][C]11.505[/C][C]30.6029872975333[/C][/ROW]
[ROW][C]22[/C][C]10[/C][C]28.69318856778[/C][/ROW]
[ROW][C]23[/C][C]5.5[/C][C]26.823869711002[/C][/ROW]
[ROW][C]24[/C][C]27.5[/C][C]24.6914827399018[/C][/ROW]
[ROW][C]25[/C][C]0.5[/C][C]24.9723344659116[/C][/ROW]
[ROW][C]26[/C][C]7[/C][C]22.5251010193204[/C][/ROW]
[ROW][C]27[/C][C]0[/C][C]20.9725909173884[/C][/ROW]
[ROW][C]28[/C][C]2.5[/C][C]20.9725909173884[/C][/ROW]
[ROW][C]29[/C][C]0[/C][C]17.3866652960451[/C][/ROW]
[ROW][C]30[/C][C]0[/C][C]17.3866652960451[/C][/ROW]
[ROW][C]31[/C][C]6.025[/C][C]17.3866652960451[/C][/ROW]
[ROW][C]32[/C][C]1[/C][C]13.8103090256470[/C][/ROW]
[ROW][C]33[/C][C]0[/C][C]12.7944240910199[/C][/ROW]
[ROW][C]34[/C][C]0[/C][C]12.7944240910199[/C][/ROW]
[ROW][C]35[/C][C]0[/C][C]12.7944240910199[/C][/ROW]
[ROW][C]36[/C][C]0[/C][C]12.7944240910199[/C][/ROW]
[ROW][C]37[/C][C]2[/C][C]12.7944240910199[/C][/ROW]
[ROW][C]38[/C][C]0[/C][C]9.00384849281212[/C][/ROW]
[ROW][C]39[/C][C]6[/C][C]9.00384849281212[/C][/ROW]
[ROW][C]40[/C][C]20[/C][C]8.2854312890366[/C][/ROW]
[ROW][C]41[/C][C]0[/C][C]9.0156435359206[/C][/ROW]
[ROW][C]42[/C][C]0[/C][C]9.0156435359206[/C][/ROW]
[ROW][C]43[/C][C]0[/C][C]9.0156435359206[/C][/ROW]
[ROW][C]44[/C][C]7[/C][C]9.0156435359206[/C][/ROW]
[ROW][C]45[/C][C]35[/C][C]7.43944706314875[/C][/ROW]
[ROW][C]46[/C][C]0[/C][C]9.00587005590655[/C][/ROW]
[ROW][C]47[/C][C]0[/C][C]9.00587005590655[/C][/ROW]
[ROW][C]48[/C][C]0[/C][C]9.00587005590655[/C][/ROW]
[ROW][C]49[/C][C]1[/C][C]9.00587005590655[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=75866&T=2

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=75866&T=2

As an alternative you can also use a QR Code:  

The GUIDs for individual cells are displayed in the table below:

Actuals and Interpolation
TimeActualForecast
162NA
23062
33158.8
45056.02
53355.418
61253.1762
72049.05858
83046.152722
921.544.5374498
102342.23370482
1113.540.310334338
120.537.6293009042
131233.91637081378
141031.724733732402
1570.529.5522603591618
163033.6470343232456
1720.533.2823308909211
181232.0040978018290
192030.0036880216461
204529.0033192194815
2111.50530.6029872975333
221028.69318856778
235.526.823869711002
2427.524.6914827399018
250.524.9723344659116
26722.5251010193204
27020.9725909173884
282.520.9725909173884
29017.3866652960451
30017.3866652960451
316.02517.3866652960451
32113.8103090256470
33012.7944240910199
34012.7944240910199
35012.7944240910199
36012.7944240910199
37212.7944240910199
3809.00384849281212
3969.00384849281212
40208.2854312890366
4109.0156435359206
4209.0156435359206
4309.0156435359206
4479.0156435359206
45357.43944706314875
4609.00587005590655
4709.00587005590655
4809.00587005590655
4919.00587005590655







\begin{tabular}{lllllllll}
\hline
What is next? \tabularnewline
Simulate Time Series \tabularnewline
Generate Forecasts \tabularnewline
Forecast Analysis \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=75866&T=3

[TABLE]
[ROW][C]What is next?[/C][/ROW]
[ROW][C]Simulate Time Series[/C][/ROW]
[ROW][C]Generate Forecasts[/C][/ROW]
[ROW][C]Forecast Analysis[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=75866&T=3

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=75866&T=3

As an alternative you can also use a QR Code:  

The GUIDs for individual cells are displayed in the table below:

What is next?
Simulate Time Series
Generate Forecasts
Forecast Analysis



Parameters (Session):
par1 = Input box ; par2 = Croston ; par3 = NA ; par4 = NA ; par5 = ZZZ ; par6 = 12 ; par7 = dum ; par8 = dumresult ; par9 = 3 ; par10 = 0.1 ;
Parameters (R input):
par1 = Input box ; par2 = Croston ; par3 = NA ; par4 = NA ; par5 = ZZZ ; par6 = 12 ; par7 = dum ; par8 = dumresult ; par9 = 3 ; par10 = 0.1 ;
R code (references can be found in the software module):
if(par3!='NA') par3 <- as.numeric(par3) else par3 <- NA
if(par4!='NA') par4 <- as.numeric(par4) else par4 <- NA
par6 <- as.numeric(par6) #Seasonal Period
par9 <- as.numeric(par9) #Forecast Horizon
par10 <- as.numeric(par10) #Alpha
library(forecast)
if (par1 == 'CSV') {
xarr <- read.csv(file=paste('tmp/',par7,'.csv',sep=''),header=T)
numseries <- length(xarr[1,])-1
n <- length(xarr[,1])
nmh <- n - par9
nmhp1 <- nmh + 1
rarr <- array(NA,dim=c(n,numseries))
farr <- array(NA,dim=c(n,numseries))
parr <- array(NA,dim=c(numseries,8))
colnames(parr) = list('ME','RMSE','MAE','MPE','MAPE','MASE','ACF1','TheilU')
for(i in 1:numseries) {
sindex <- i+1
x <- xarr[,sindex]
if(par2=='Croston') {
if (i==1) m <- croston(x,alpha=par10)
if (i==1) mydemand <- m$model$demand[]
fit <- croston(x[1:nmh],h=par9,alpha=par10)
}
if(par2=='ARIMA') {
m <- auto.arima(ts(x,freq=par6),d=par3,D=par4)
mydemand <- forecast(m)
fit <- auto.arima(ts(x[1:nmh],freq=par6),d=par3,D=par4)
}
if(par2=='ETS') {
m <- ets(ts(x,freq=par6),model=par5)
mydemand <- forecast(m)
fit <- ets(ts(x[1:nmh],freq=par6),model=par5)
}
try(rarr[,i] <- mydemand$resid,silent=T)
try(farr[,i] <- mydemand$mean,silent=T)
if (par2!='Croston') parr[i,] <- accuracy(forecast(fit,par9),x[nmhp1:n])
if (par2=='Croston') parr[i,] <- accuracy(fit,x[nmhp1:n])
}
write.csv(farr,file=paste('tmp/',par8,'_f.csv',sep=''))
write.csv(rarr,file=paste('tmp/',par8,'_r.csv',sep=''))
write.csv(parr,file=paste('tmp/',par8,'_p.csv',sep=''))
}
if (par1 == 'Input box') {
numseries <- 1
n <- length(x)
if(par2=='Croston') {
m <- croston(x)
mydemand <- m$model$demand[]
}
if(par2=='ARIMA') {
m <- auto.arima(ts(x,freq=par6),d=par3,D=par4)
mydemand <- forecast(m)
}
if(par2=='ETS') {
m <- ets(ts(x,freq=par6),model=par5)
mydemand <- forecast(m)
}
summary(m)
}
bitmap(file='test1.png')
op <- par(mfrow=c(2,1))
if (par2=='Croston') plot(m)
if ((par2=='ARIMA') | par2=='ETS') plot(forecast(m))
plot(mydemand$resid,type='l',main='Residuals', ylab='residual value', xlab='time')
par(op)
dev.off()
bitmap(file='pic2.png')
op <- par(mfrow=c(2,2))
acf(mydemand$resid, lag.max=n/3, main='Residual ACF', ylab='autocorrelation', xlab='time lag')
pacf(mydemand$resid,lag.max=n/3, main='Residual PACF', ylab='partial autocorrelation', xlab='time lag')
cpgram(mydemand$resid, main='Cumulative Periodogram of Residuals')
qqnorm(mydemand$resid); qqline(mydemand$resid, col=2)
par(op)
dev.off()
load(file='createtable')
a<-table.start()
a<-table.row.start(a)
a<-table.element(a,'Demand Forecast',6,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Point',header=TRUE)
a<-table.element(a,'Forecast',header=TRUE)
a<-table.element(a,'95% LB',header=TRUE)
a<-table.element(a,'80% LB',header=TRUE)
a<-table.element(a,'80% UB',header=TRUE)
a<-table.element(a,'95% UB',header=TRUE)
a<-table.row.end(a)
for (i in 1:length(mydemand$mean)) {
a<-table.row.start(a)
a<-table.element(a,i+n,header=TRUE)
a<-table.element(a,as.numeric(mydemand$mean[i]))
a<-table.element(a,as.numeric(mydemand$lower[i,2]))
a<-table.element(a,as.numeric(mydemand$lower[i,1]))
a<-table.element(a,as.numeric(mydemand$upper[i,1]))
a<-table.element(a,as.numeric(mydemand$upper[i,2]))
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,'Actuals and Interpolation',3,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Time',header=TRUE)
a<-table.element(a,'Actual',header=TRUE)
a<-table.element(a,'Forecast',header=TRUE)
a<-table.row.end(a)
for (i in 1:n) {
a<-table.row.start(a)
a<-table.element(a,i,header=TRUE)
a<-table.element(a,x[i])
a<-table.element(a,x[i] - as.numeric(m$resid[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,'What is next?',1,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,hyperlink(paste('https://automated.biganalytics.eu/Patrick.Wessa/rwasp_demand_forecasting_simulate.wasp',sep=''),'Simulate Time Series','',target=''))
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,hyperlink(paste('https://automated.biganalytics.eu/Patrick.Wessa/rwasp_demand_forecasting_croston.wasp#output',sep=''),'Generate Forecasts','',target=''))
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,hyperlink(paste('https://automated.biganalytics.eu/Patrick.Wessa/rwasp_demand_forecasting_analysis.wasp',sep=''),'Forecast Analysis','',target=''))
a<-table.row.end(a)
a<-table.end(a)
table.save(a,file='mytable0.tab')
-SERVER-wessa.org