ctprojmat | R Documentation |
This function computes the projection or the mapping matrix
\mathbf{M}
and \mathbf{G}
, respectively, such that
\widetilde{\mathbf{y}} = \mathbf{M}\widehat{\mathbf{y}} = \mathbf{S}_{ct}\mathbf{G}\widehat{\mathbf{y}}
,
where \widetilde{\mathbf{y}}
is the vector of the reconciled forecasts,
\widehat{\mathbf{y}}
is the vector of the base forecasts,
\mathbf{S}_{ct}
is the cross-temporal structural matrix, and \mathbf{M} = \mathbf{S}_{ct}\mathbf{G}
.
For further information regarding on the structure of these matrices,
refer to Girolimetto et al. (2023).
ctprojmat(agg_mat, cons_mat, agg_order, comb = "ols", res = NULL,
mat = "M", tew = "sum", ...)
agg_mat |
A ( |
cons_mat |
A ( |
agg_order |
Highest available sampling frequency per seasonal cycle (max. order
of temporal aggregation, |
comb |
A string specifying the reconciliation method. For a complete list, see ctcov. |
res |
A ( |
mat |
A string specifying which matrix to return:
" |
tew |
A string specifying the type of temporal aggregation. Options include:
" |
... |
Arguments passed on to
|
The projection matrix \mathbf{M}
(mat = "M"
) or
the mapping matrix \mathbf{G}
(mat = "G"
).
Girolimetto, D., Athanasopoulos, G., Di Fonzo, T. and Hyndman, R.J. (2024), Cross-temporal probabilistic forecast reconciliation: Methodological and practical issues. International Journal of Forecasting, 40, 3, 1134-1151. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1016/j.ijforecast.2023.10.003")}
Utilities:
FoReco2matrix()
,
aggts()
,
balance_hierarchy()
,
commat()
,
csprojmat()
,
cstools()
,
cttools()
,
df2aggmat()
,
lcmat()
,
recoinfo()
,
res2matrix()
,
shrink_estim()
,
teprojmat()
,
tetools()
,
unbalance_hierarchy()
# Cross-temporal framework (Z = X + Y, annual-quarterly)
A <- t(c(1,1)) # Aggregation matrix for Z = X + Y
Mct <- ctprojmat(agg_mat = A, agg_order = 4, comb = "ols")
Gct <- ctprojmat(agg_mat = A, agg_order = 4, comb = "ols", mat = "G")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.