VECMResult._coefficient_stack#
- VECMResult._coefficient_stack()[source]#
Short-run coefficients, laid out exactly as the design columns.
Overridden because the inherited version reads
coefficients, which here is the levels representation and was never regressed. The stack has to describe the regression that produced the standard errors, not the reparameterization of it.- Return type:
- Returns:
A
(width, k)array, one row per design column – deterministic terms, then each lag’s transposedGamma, thenalpha.T.
Example
>>> import numpy as np >>> y = np.cumsum(np.random.default_rng(0).standard_normal((200, 2)), axis=0) >>> res = VECM(y, order=2, rank=1).fit() >>> stack = res._coefficient_stack() >>> stack.shape == (res.design.shape[1], 2) True >>> bool(np.allclose(stack[-1], res.alpha[:, 0])) True >>> bool(np.allclose(res.design @ stack, res.fittedvalues)) True