SparseVARResult._summary_table#

SparseVARResult._summary_table()[source]#

Build the structured summary.

Return type:

SummaryTable

Returns:

One row per equation with its count of nonzero lag regressors and the variable’s Granger out-degree at threshold 0; the metadata carries the penalty, the level, the nonzero count and the sparsity; the notes state how the level was chosen, the forecast-versus-support caveat, the absence of inference, and the closed-system contract.

Example

>>> import numpy as np
>>> rng = np.random.default_rng(0)
>>> y = np.zeros((200, 3))
>>> for t in range(1, 200):
...     y[t] = 0.5 * y[t - 1] + rng.standard_normal(3)
>>> table = SparseVAR(y, order=1).fit(penalty="lasso")._summary_table()
>>> table.title, table.columns, len(table.rows), len(table.notes)
('Sparse VAR(1) Results', ('equation', 'nonzero regressors', 'out-degree'), 3, 4)
>>> table.metadata[0], table.notes[0][-48:]
(('Model', 'lasso-VAR(1)'), 'cross-validation with refitting at every origin.')
>>> SparseVAR(y, order=1).fit(lam=0.1)._summary_table().notes[0][-22:]
' stated by the caller.'