{"id":13688988,"url":"https://github.com/aschleg/hypothetical","last_synced_at":"2025-04-09T16:15:25.506Z","repository":{"id":44478094,"uuid":"118410697","full_name":"aschleg/hypothetical","owner":"aschleg","description":"Hypothesis and statistical testing in Python","archived":false,"fork":false,"pushed_at":"2020-08-20T20:06:17.000Z","size":873,"stargazers_count":64,"open_issues_count":5,"forks_count":10,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-04-09T16:15:08.716Z","etag":null,"topics":["analysis","comparison-tests","frequentist-methods","frequentist-statistics","hypothesis","hypothesis-testing","inferential-statistics","nonparametric-statistics","nonparametric-tests","python","statistical-inference","statistical-tests","statistics","statistics-library"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/aschleg.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-01-22T05:29:05.000Z","updated_at":"2024-10-30T13:17:06.000Z","dependencies_parsed_at":"2022-08-29T01:31:27.085Z","dependency_job_id":null,"html_url":"https://github.com/aschleg/hypothetical","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aschleg%2Fhypothetical","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aschleg%2Fhypothetical/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aschleg%2Fhypothetical/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aschleg%2Fhypothetical/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/aschleg","download_url":"https://codeload.github.com/aschleg/hypothetical/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248065282,"owners_count":21041872,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["analysis","comparison-tests","frequentist-methods","frequentist-statistics","hypothesis","hypothesis-testing","inferential-statistics","nonparametric-statistics","nonparametric-tests","python","statistical-inference","statistical-tests","statistics","statistics-library"],"created_at":"2024-08-02T15:01:29.641Z","updated_at":"2025-04-09T16:15:25.484Z","avatar_url":"https://github.com/aschleg.png","language":"Python","funding_links":[],"categories":["Python"],"sub_categories":[],"readme":"# hypothetical - Hypothesis and Statistical Testing in Python\n\n[![Build Status](https://travis-ci.org/aschleg/hypothetical.svg?branch=master)](https://travis-ci.org/aschleg/hypothetical)\n[![Build status](https://ci.appveyor.com/api/projects/status/i1i1blt9ny3tyi6a?svg=true)](https://ci.appveyor.com/project/aschleg/hypy)\n[![Coverage Status](https://coveralls.io/repos/github/aschleg/hypothetical/badge.svg?branch=master)](https://coveralls.io/github/aschleg/hypothetical?branch=master)\n[![Codacy Badge](https://api.codacy.com/project/badge/Grade/3ceba919fdb34d45af43c044a761ddb8)](https://www.codacy.com/app/aschleg/hypothetical?utm_source=github.com\u0026amp;utm_medium=referral\u0026amp;utm_content=aschleg/hypothetical\u0026amp;utm_campaign=Badge_Grade)\n[![Dependencies](https://img.shields.io/librariesio/github/aschleg/hypothetical.svg?label=dependencies)](https://libraries.io/github/aschleg/hypothetical)\n![Python versions](https://img.shields.io/badge/python-3.5%2C%203.6%2C%203.7-blue.svg)\n\nPython library for conducting hypothesis and other group comparison tests.\n\n## Installation\n\nThe best way to install `hypothetical` is through `pip`.\n\n```bash\npip install hypothetical\n```\n\nFor those interested, the most recent development version of the library can also be installed by cloning or \ndownloading the repo.\n\n~~~ bash\ngit clone git@github.com:aschleg/hypothetical.git\ncd hypothetical\npython setup.py install\n~~~\n\n## Available Methods\n\n### Analysis of Variance\n\n* One-way Analysis of Variance (ANOVA)\n* One-way Multivariate Analysis of Variance (MANOVA)\n* Bartlett's Test for Homogenity of Variances\n* Levene's Test for Homogenity of Variances\n* Van Der Waerden's (normal scores) Test\n\n### Contingency Tables and Related Tests\n\n* Chi-square test of independence\n* Fisher's Exact Test\n* McNemar's Test of paired nominal data\n* Cochran's Q test\n* D critical value (used in the Kolomogorov-Smirnov Goodness-of-Fit test).\n\n### Critical Value Tables and Lookup Functions\n\n* Chi-square statistic\n* r (one-sample runs test and Wald-Wolfowitz runs test) statistic \n* Mann-Whitney U-statistic\n* Wilcoxon Rank Sum W-statistic\n\n### Descriptive Statistics\n\n* Kurtosis\n* Skewness\n* Mean Absolute Deviation\n* Pearson Correlation\n* Spearman Correlation\n* Covariance\n  - Several algorithms for computing the covariance and covariance matrix of \n    sample data are available\n* Variance\n  - Several algorithms are also available for computing variance.\n* Simulation of Correlation Matrices\n  - Multiple simulation algorithms are available for generating correlation matrices.\n\n### Factor Analysis\n\n* Several algorithms for performing Factor Analysis are available, including principal components, principal \n      factors, and iterated principal factors.\n\n### Hypothesis Testing\n\n* Binomial Test\n* t-test\n  - paired, one and two sample testing\n\n### Nonparametric Methods\n\n* Friedman's test for repeated measures\n* Kruskal-Wallis (nonparametric equivalent of one-way ANOVA)\n* Mann-Whitney (two sample nonparametric variant of t-test)\n* Mood's Median test\n* One-sample Runs Test\n* Wald-Wolfowitz Two-Sample Runs Test\n* Sign test of consistent differences between observation pairs\n* Wald-Wolfowitz Two-Sample Runs test\n* Wilcoxon Rank Sum Test (one sample nonparametric variant of paired and one-sample t-test)\n\n### Normality and Goodness-of-Fit Tests\n\n* Chi-square one-sample goodness-of-fit\n* Jarque-Bera test\n\n### Post-Hoc Analysis\n\n* Tukey's Honestly Significant Difference (HSD)\n* Games-Howell (nonparametric)\n\n### Helpful Functions\n\n* Add noise to a correlation or other matrix\n* Tie Correction for ranked variables\n* Contingency table marginal sums\n* Contingency table expected frequencies\n* Runs and count of runs\n\n## Goal\n\nThe goal of the `hypothetical` library is to help bridge the gap in statistics and hypothesis testing \ncapabilities of Python closer to that of R. Python has absolutely come a long way with several popular and \namazing libraries that contain a myriad of statistics functions and methods, such as [`numpy`](http://www.numpy.org/), \n[`pandas`](https://pandas.pydata.org/), and [`scipy`](https://www.scipy.org/); however, it is my humble opinion that \nthere is still more that can be done to make Python an even better language for data and statistics computation. Thus, \nit is my hope with the `hypothetical` library to build on top of the wonderful Python packages listed earlier and \ncreate an easy-to-use, feature complete, statistics library. At the end of the day, if the library helps a user \nlearn more about statistics or get the information they need in an easy way, then I consider that all the success \nI need!\n\n## Requirements\n\n* Python 3.5+\n* `numpy\u003e=1.13.0`\n* `numpy_indexed\u003e=0.3.5`\n* `pandas\u003e=0.22.0`\n* `scipy\u003e=1.1.0`\n* `statsmodels\u003e=0.9.0`\n\n## License\n\nMIT","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faschleg%2Fhypothetical","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Faschleg%2Fhypothetical","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faschleg%2Fhypothetical/lists"}