Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/mfreidank/arspy

Adaptive Rejection Sampling for Python
https://github.com/mfreidank/arspy

adaptive adaptive-rejection-sampling ars python rejection-sampling sampling statistics

Last synced: 2 months ago
JSON representation

Adaptive Rejection Sampling for Python

Awesome Lists containing this project

README

        

========
ARSPY
========

|Build Status|
|Docs_|
|Coverage_|
|Pypi_|

This package provides a pure python/numpy
implementation of adaptive rejection sampling as
proposed by P. Wild, W.R. Gilks in
*Algorithm AS 287: Adaptive Rejection Sampling from Log Concave Density
functions*.

Under the (frequently satisfied) assumption that the target distribution to
sample from has a log-concave density function, this algorithm allows us
to sample without calculating any integrals.

This sampling method is *exact* (all resulting samples are i.i.d) and
*efficient* and our implementation can handle any univariate log-concave
distribution.

One prime use case is Gibbs sampling, where one frequently encounters many
1D log-concave distributions.

Install
=======

Simply run::

pip3 install ARSpy

.. |Build Status| image:: https://travis-ci.org/MFreidank/ARSpy.svg?branch=master
:target: https://travis-ci.org/MFreidank/ARSpy

.. |Coverage_| image:: https://coveralls.io/repos/github/MFreidank/pyARS/badge.svg
:target: https://coveralls.io/github/MFreidank/pyARS
:alt: Coverage

.. |Docs_| image:: https://readthedocs.org/projects/arspy/badge/?version=latest
:target: http://ARSpy.readthedocs.io/en/latest/
:alt: Docs

.. |Pypi_| image:: https://badge.fury.io/py/ARSpy.svg
:target: https://badge.fury.io/py/ARSpy

Documentation
=============
Our documentation can be found at http://arspy.readthedocs.io/en/latest/.