# statsmodels.stats.diagnostic.HetGoldfeldQuandt¶

class statsmodels.stats.diagnostic.HetGoldfeldQuandt[source]

test whether variance is the same in 2 subsamples

Parameters: y (array_like) – endogenous variable x (array_like) – exogenous variable, regressors idx (integer) – column index of variable according to which observations are sorted for the split split (None or integer or float in intervall (0,1)) – index at which sample is split. If 0

Notes

The Null hypothesis is that the variance in the two sub-samples are the same. The alternative hypothesis, can be increasing, i.e. the variance in the second sample is larger than in the first, or decreasing or two-sided.

Results are identical R, but the drop option is defined differently. (sorting by idx not tested yet)

Methods

 run(y, x[, idx, split, drop, alternative, …]) see class docstring