Repository navigation
ENH: added chi^2 effect size in contingency table class, closes #6184 - #6598
zhaobinlidev wants to merge 3 commits into
Conversation
|
Thanks for the PR Avoid autoformatting code that is not related to the PR. It makes it difficult to see what changes are made if the PR has a lot of additional "cosmetic" changes. question about attribute effectsize is not important for internal followup computation, so we don't really need to chache it. should it be a method? I'm not familiar enough in this area to tell, but for t-test and anova, we would need to use options because there are variations in the definition of the effect sizes. |
|
@kshedden any comments to this kind of extensions? |
|
related, since I'm looking at effect size for other statistics. Is there a literature for confidence intervals of the effect size for this case? I guess for future compatibility it should be a method even if we don't have any extensions right away. |
Codecov Report
@@ Coverage Diff @@
## master #6598 +/- ##
==========================================
- Coverage 85.28% 85.27% -0.01%
==========================================
Files 646 646
Lines 103607 103624 +17
Branches 11270 11270
==========================================
+ Hits 88358 88364 +6
- Misses 12793 12805 +12
+ Partials 2456 2455 -1
Continue to review full report at Codecov.
|
|
Hi @josef-pkt, I realize that using pd dataframes as unit testing break the code, so I have updated the code again. Not sure about CIs around chi^2 effect size, though I certainly think is possible. The effect size could be extend as a method with options. For now I am putting effsize together with the p values and statistic under test_nominal_association because I think these concepts come together and make things neater. We could easily refactor the effect size as a method once we have more options. Checked code with sphinx and pytest. Thank you. Regards, |
|
If needed, we could add effect size options to test_nominal_association, since the effect size I implement is particular to nominal tables |
|
core change here looks good (ignoring pep-8 formatting changes) I don't know or remember enough about other effect size definitions and options. We might need more specific names like effectsize_chi2. |
NumPy's guide.
Details
Notes:
needed for doc changes.
then show that it is fixed with the new code.
verify you changes are well formatted by running
flake8is installed. This command is also available on Windowsusing the Windows System for Linux once
flake8is installed in thelocal Linux environment. While passing this test is not required, it is good practice and it help
improve code quality in
statsmodels.