gmm.GMMEstimator

Guide & worked example · Source

gmm.GMMEstimator(
    moment_cond,
    weighting_matrix='optimal',
    backend='scipy',
    device=None,
)

Dispatch to a SciPy or Torch GMM implementation.

weighting_matrix is ‘optimal’ (two-step), ‘identity’, or a fixed symmetric positive-definite matrix. init_params in fit defaults to zeros with x.shape[1] entries; pass it for other parameter dimensions.

Attributes

Name Description
W_
device
moment_cond
std_errors_
theta_
weighting_matrix

Methods

Name Description
fit
gmm_objective
jacobian_moment_cond
optimal_weighting_matrix
summary

fit

gmm.GMMEstimator.fit(
    z,
    y,
    x,
    verbose=False,
    fit_method=None,
    iid=True,
    two_step=True,
    *,
    init_params=None,
    max_lags=None,
    tol=1e-09,
    maxiter=2000,
)

gmm_objective

gmm.GMMEstimator.gmm_objective(beta)

jacobian_moment_cond

gmm.GMMEstimator.jacobian_moment_cond()

optimal_weighting_matrix

gmm.GMMEstimator.optimal_weighting_matrix(moments)

summary

gmm.GMMEstimator.summary(prec=4, alpha=0.05)