linearmodels.iv.gmm.IVGMMCovariance¶
-
class linearmodels.iv.gmm.IVGMMCovariance(x: ndarray[tuple[int, ...], dtype[float64]], y: ndarray[tuple[int, ...], dtype[float64]], z: ndarray[tuple[int, ...], dtype[float64]], params: ndarray[tuple[int, ...], dtype[float64]], w: ndarray[tuple[int, ...], dtype[float64]], cov_type: str =
'robust', debiased: bool =False, **cov_config: str | bool)[source]¶ Covariance estimation for GMM models
- Parameters:¶
- x: ndarray[tuple[int, ...], dtype[float64]]¶
Model regressors (nobs by nvar)
- y: ndarray[tuple[int, ...], dtype[float64]]¶
Series ,modeled (nobs by 1)
- z: ndarray[tuple[int, ...], dtype[float64]]¶
Instruments used for endogenous regressors (nobs by ninstr)
- params: ndarray[tuple[int, ...], dtype[float64]]¶
Estimated model parameters (nvar by 1)
- w: ndarray[tuple[int, ...], dtype[float64]]¶
Weighting matrix used in GMM estimation
- cov_type: str =
'robust'¶ Covariance estimator to use Valid choices are
”unadjusted”, “homoskedastic” - Assumes moment conditions are homoskedastic
”robust”, “heteroskedastic” - Allows for heteroskedasticity by not autocorrelation
”kernel” - Allows for heteroskedasticity and autocorrelation
”clustered” - Allows for one-way cluster dependence
- debiased: bool =
False¶ Flag indicating whether to debias the covariance estimator
- **cov_config: str | bool¶
Optional keyword arguments that are specific to a particular cov_type
Notes
Optional keyword argument for specific covariance estimators:
kernel
kernel: Name of kernel to use. SeeKernelCovariancefor details on available kernelsbandwidth: Bandwidth to use when computing the weight. If not provided, nobs - 2 is used.
cluster
clusters: Array containing the cluster indices. SeeClusteredCovariance
See also
linearmodels.iv.covariance.HomoskedasticCovariance,linearmodels.iv.covariance.HeteroskedasticCovariance,linearmodels.iv.covariance.KernelCovariance,linearmodels.iv.covariance.ClusteredCovarianceMethods
Properties
Covariance of estimated parameters
Flag indicating if covariance is debiased
Score covariance estimate
Estimated variance of residuals.