statsmodels.stats.rates.PowerResult#

class statsmodels.stats.rates.PowerResult(*, power, std_alt, nobs_1, nobs_2, nobs_ratio, alpha)[source]#

Common base for the power-computation result classes in this module.

Behaves like the scalar power when converted to an array, e.g., with np.asarray or in numpy.testing.assert_allclose, so that it can be compared directly against a plain power value.

Parameters:
powerfloat

Power of the test.

std_altfloat

Standard error of the test statistic under the alternative hypothesis (without sqrt(nobs_1)).

nobs_1float or int

Number of observations in sample 1.

nobs_2float or int

Number of observations in sample 2.

nobs_ratiofloat

Sample size ratio, nobs_2 = nobs_ratio * nobs_1.

alphafloat

Significance level used for the power computation.

Attributes:
alpha
nobs_1
nobs_2
nobs_ratio
power
std_alt

Notes

Unpacks as a length-1 sequence, (power,) = result. Other values are only accessible using attributes.

Methods

Properties