A collection of statistical functions

version: 0.2.0

This repository collects an assortment of python-based statistical modules covering, testing, (interval) estimation, resampling, regression (e.g. Firth’s logistic regression), and other machine learning functions.

The documentation for stats-misc can be found here.

Installation

At present, the repository is undergoing development and no packages exist yet on PyPy or in Conda. Therefore it is recommended that it is installed in either of the two ways listed below. First, clone this repository and then cd to the root of the repository.

git clone git@gitlab.com:SchmidtAF/stats-misc.git
cd stat-misc

Installation using conda dependencies

A conda environment is provided in a yaml file in the directory ./resources/conda_env/. A new conda environment called stat-misc can be built using the command:

# From the root of the repository
conda env create --file ./resources/conda/conda_create.yml

To add to an existing environment use:

# From the root of the repository
conda env update --file ./resources/conda_env/conda_create.yml

Next the package can be installed:

python -m pip install .

Or for an editable (developer) install run the command below from the root of the repository. The difference with this is that you can just to a git pull to update repository, or switch branches without re-installing:

python -m pip install -e .

Installation not using any conda dependencies

If you are not using conda in any way then install the dependencies via pip and install repository as an editable install also via pip:

Install dependencies:

python -m pip install --upgrade -r requirements.txt

Then to install repository you can either do:

python -m pip install .

Or for an editable (developer) install run the command below from the root of the repository. The difference with this is that you can just to a git pull to update repository, or switch branches without re-installing:

python -m pip install -e .

Next steps…

After installation you might wish to try the pytest to confirm everything is in working order.

# From the root of the repository
pytest tests

Usage

Please have a look at the examples in resources .