A Python Based Library to Calculate Estimators (Sn, Qn, MAD, IQR)
Project description
robustbase
A Python Library to Calculate Robust Statistical Estimators.
Installation
OS X, Windows & Linux:
pip install robustbase
Usage Example
This package provides functions to calculate the following robust statistical estimators:
- Qn Scale Estimator
- Computes the robust scale estimator Qn, an efficient alternative to the MAD. Read More
from robustbase.stats import Qn
x = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10]
# With bias correction
res = Qn(x) # result: 3.196183
# Without bias correction
res = Qn(x, finite_corr=False) # result: 4.43828
- Sn Scale Estimator
- Computes the robust scale estimator Sn, an efficient alternative to the MAD. Read More
from robustbase.stats import Sn
x = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10]
# With bias correction
res = Sn(x) # result: 3.5778
# Without bias correction
res = Sn(x, finite_corr=False) # result: 3.5778
- Median Absolute Deviation (MAD)
- Compute the MAD, a robust measure of the variability of a univariate sample of quantitative data. Read More
from robustbase.stats import mad
x = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10]
res = mad(x)
- Interquartile Range (IQR)
- Compute the interquartile range, a measure of statistical dispersion, or spread. Read More
from robustbase.stats import iqr
x = [1, 2, 3, 4, 5]
res = iqr(x)
Development Setup
For local development setup:
git clone https://github.com/deepak7376/robustbase
cd robustbase
pip install -r requirements.txt -r requirements-dev.txt
Recent Changes
Version 3.0.0
- Changed the API's call
- Refactored the dir structure
- Updated README with usage examples for all functions.
Contributing
- Fork it (https://github.com/deepak7376/robustbase/fork)
- Create your feature branch (
git checkout -b feature/fooBar
) - Commit your changes (
git commit -am 'Add some fooBar'
) - Push to the branch (
git push origin feature/fooBar
) - Create a new Pull Request
References
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
robustbase-3.0.8.tar.gz
(8.8 kB
view hashes)
Built Distribution
Close
Hashes for robustbase-3.0.8-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | c7cef93b5c3abc7a33c5a8ee26f2a5a04c4bab94f60838bc782d58d0fc695c66 |
|
MD5 | 55457781dd00d986843243f730431674 |
|
BLAKE2b-256 | 247d6a1a8680cb7f29ccf8a7196a0ff026969a8e0f9b7058b651af755947afd4 |