Description Usage Arguments Details

View source: R/seriesToBlock.R

The functions `seriesToBlock`

and `blockToSeries`

convert 1-dimensional series into series of higher dimension.
For instance, suppose you have a time-series that consists of *T = 100* days of *d = 24* hours.
The function seriesToBlock converts the time-series X of *Td = 2400* observations into a matrix of size `c(T=100,d =24)`

,
where each line corresponds to a specific day. This function is usefull if you need to perform the prediction day by day, instead of hour by hour.
The function can also be used to convert a matrix of expert prediction of dimension `c(dT,K)`

where K is the number of experts,
into an array of dimension `c(T,d,K)`

. The new arrays of observations and of expert predictions can be
given to the aggregation rule procedure to perform `d`

-dimensional predictions (i.e., day predictions).

1 2 3 | ```
seriesToBlock(X, d)
blockToSeries(X)
``` |

`X` |
An array or a vector to be converted. |

`d` |
A positive integer defining the block size. |

The function blockToSeries performs the inverse operation.

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.