, *, reweight: bool = False, cov_type: str = 'unadjusted', debiased: bool = True, **cov_config: Union[bool, float, str, numpy.ndarray, pandas.core.frame.DataFrame,]) → linearmodels.panel.results.PanelResults[source]

Estimate model parameters


Flag indicating to reweight observations if the input data is unbalanced using a WLS estimator. If weights are provided, these are accounted for when reweighting. Has no effect on balanced data.

cov_typestr, optional

Name of covariance estimator. See Notes.

debiasedbool, optional

Flag indicating whether to debiased the covariance estimator using a degree of freedom adjustment.


Additional covariance-specific options. See Notes.


Estimation results


Three covariance estimators are supported:

  • ‘unadjusted’, ‘homoskedastic’ - Assume residual are homoskedastic

  • ‘robust’, ‘heteroskedastic’ - Control for heteroskedasticity using White’s estimator

  • ‘clustered` - One or two way clustering. Configuration options are:

    • clusters - Input containing containing 1 or 2 variables. Clusters should be integer values, although other types will be coerced to integer values by treating as categorical variables

When using a clustered covariance estimator, all cluster ids must be identical within an entity.


>>> from linearmodels import BetweenOLS
>>> mod = BetweenOLS(y, x)
>>> res ='robust')
Return type