linearmodels.shared.covariance.group_debias_coefficient

linearmodels.shared.covariance.group_debias_coefficient(clusters: ndarray) float[source]

Compute the group debiasing scale.

Parameters:
clusters: ndarray

One-dimensional array containing cluster group membership.

Returns:

The scale to debias.

Return type:

float

Notes

The debiasing coefficient is defined

\[`\frac{g}{g-1}\frac{n-1}{n}`\]

where g is the number of groups and n is the sample size.