statsmodels.stats.proportion.Proportions2indepTestResult#
- class statsmodels.stats.proportion.Proportions2indepTestResult(statistic, pvalue, compare, method, diff, ratio, odds_ratio, variance, alternative, value, prop1_null=None, prop2_null=None)[source]#
Result of
test_proportions_2indep.- Parameters:
- statistic
float Test statistic, asymptotically normal distributed N(0, 1).
- pvalue
float p-value based on the normal distribution.
- compare{“diff”, “ratio”, “odds-ratio”}
Which comparison of the two proportions the test is for.
- method
str Method used to compute the test.
- diff
float Observed difference,
prop1 - prop2.- ratio
float Observed risk ratio,
prop1 / prop2.- odds_ratio
float Observed odds ratio.
- variance
float Estimated variance of the test statistic under the null hypothesis.
- alternative
str The alternative hypothesis used for the test.
- value
float Value of the difference, risk ratio or odds ratio under the null hypothesis.
- prop1_null
floatorNone Constrained estimate of the first proportion under the null hypothesis. Only set if
method="score", otherwise None.- prop2_null
floatorNone Constrained estimate of the second proportion under the null hypothesis. Only set if
method="score", otherwise None.
- statistic
- Attributes:
- alternative
- compare
- diff
- method
- odds_ratio
- prop1_null
- prop2_null
- pvalue
- ratio
- statistic
- value
- variance
Notes
Unpacks as
statistic, pvalue = result. Other values are only accessible using attributes.Methods
Properties