Metadata-Version: 2.1
Name: RankBasedMonteCarlo
Version: 0.1.4
Summary: A set of Monte Carlo based tools to create test statistics for four non-parametric rank-based tests: Mann-Whitney (MW), Kruskal-Wallis (KW), Kolmogorov-Smirnov (KS) and Kuiper (K).
Project-URL: Homepage, https://github.com/tazzben/RankBasedMonteCarlo
Project-URL: Bug Tracker, https://github.com/tazzben/RankBasedMonteCarlo/issues
Author-email: Ben Smith <bosmith@unomaha.edu>
Maintainer-email: Ben Smith <bosmith@unomaha.edu>
License-Expression: MIT
License-File: LICENSE
Keywords: Monte Carlo,Rank based,Statistics
Classifier: Development Status :: 5 - Production/Stable
Classifier: Intended Audience :: Science/Research
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Requires-Python: >=3.8
Requires-Dist: numpy>=1.21.0
Requires-Dist: pandas>=1.3.0
Requires-Dist: tqdm>=4.26.0
Description-Content-Type: text/markdown

# Rank Based Monte Carlo

This package produces the null hypothesis distribution of four non-parametric tests: Mann-Whitney (MW), Kruskal-Wallis (KW), Kolmogorov-Smirnov (KS) and Kuiper (K). 

In all cases, the distribution is created by initializing the class (MonteCarloMannWhitney, MonteCarloKruskalWallis, MonteCarloKolmogorovSmirnov, MonteCarloKuiper) from the package and calling the method PrintCriticalValueTable.  For instance, the KW test statistics can be accomplished with the following code:

~~~

from RankBasedMonteCarlo import MonteCarloKruskalWallis

if __name__ == '__main__':
    kw = MonteCarloKruskalWallis()
    criticalValues, pvalue = kw.PrintCriticalValueTable((6, 45, 30), 10000, 9)

~~~


The class is imported from the package on the first line.  Within the if statement, an instance of the class is created (kw) and the critical values and pvalue is determined on the next line.  The PrintCriticalValueTable method accepts the same parameters regardless of the statistical test:


1. ns : tuple : A tuple listing the number of observations per group.  For instance (6,5)
2. reps : int : The number of repetitions the process completes before producing critical values.  Default is 10,000.
3. observedValue : float : Optional value used to determine p-value
4. PrintToScreen : bool : Specifies if the critical values are printed to the screen.  Defaults to True.
5. cvs : list : Specifies a list of critical values.

## Installation

This package can be installed using pip or conda (Anaconda):

### Using Pip

~~~

pip install RankBasedMonteCarlo

~~~		

### Using Conda

~~~

conda install -c tazzben rankbasedmontecarlo

~~~