Skip to main content

Bayesian Additive Regression Trees for Probabilistic programming with PyMC

Project description

Bayesian Additive Regression Trees for Probabilistic Programming with PyMC

pymc-bart logo

PyMC-BART extends PyMC probabilistic programming framework to be able to define and solve models including a BART random variable. PyMC-BART also includes a few helpers function to aid with the interpretation of those models and perform variable selection.

Table of Contents

Installation

PyMC-BART is available on Conda-Forge. If you magange your Python dependencies and environments with Conda, this is your best option. You may also perfer to install this way if you want an easy-to-use, isolated setup in a seperate environment. This helps avoid interfering with other projects or system-wide Python installations. To set up a suitable Conda environment, run:

conda create --name=pymc-bart --channel=conda-forge pymc-bart
conda activate pymc-bart

Alternatively, you can use pip installation. This installation is generally perfered by users who use pip, Python's package installer. This is the best choice for users who are not using Conda or for those who want to install PyMC-BART into a virtual environment managed by venv or virtualenv. In this case, run:

pip install pymc-bart

In case you want to upgrade to the bleeding edge version of the package you can install from GitHub:

pip install git+https://github.com/pymc-devs/pymc-bart.git

Usage

Get started by using PyMC-BART to set up a BART model:

import pymc as pm
import pymc_bart as pmb

X, y = ... # Your data replaces "..."
with pm.Model() as model:
    bart = pmb.BART('bart', X, y)
    ...
    idata = pm.sample()

Contributions

PyMC-BART is a community project and welcomes contributions. Additional information can be found in the Contributing Readme

Code of Conduct

PyMC-BART wishes to maintain a positive community. Additional details can be found in the Code of Conduct

Citation

If you use PyMC-BART and want to cite it please use arXiv

Here is the citation in BibTeX format

@misc{quiroga2023bayesian,
title={Bayesian additive regression trees for probabilistic programming},
author={Quiroga, Miriana and Garay, Pablo G and Alonso, Juan M. and Loyola, Juan Martin and Martin, Osvaldo A},
year={2023},
doi={10.48550/ARXIV.2206.03619},
archivePrefix={arXiv},
primaryClass={stat.CO}
}

License

Apache License, Version 2.0

Donations

PyMC-BART , as other pymc-devs projects, is a non-profit project under the NumFOCUS umbrella. If you want to support PyMC-BART financially, you can donate here.

Sponsors

NumFOCUS

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pymc_bart-0.9.2.tar.gz (41.3 kB view details)

Uploaded Source

Built Distribution

pymc_bart-0.9.2-py3-none-any.whl (31.7 kB view details)

Uploaded Python 3

File details

Details for the file pymc_bart-0.9.2.tar.gz.

File metadata

  • Download URL: pymc_bart-0.9.2.tar.gz
  • Upload date:
  • Size: 41.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for pymc_bart-0.9.2.tar.gz
Algorithm Hash digest
SHA256 7509b68c2a74cec5c11691b25e34e02cc8909f2a9069c5e36680ae86260e3693
MD5 5674c8e01cb7f20a59ee080800fd6c03
BLAKE2b-256 f0f10031d51c6ad12c2d178d4394866077967552286fe1ae48569ef51bdc706e

See more details on using hashes here.

File details

Details for the file pymc_bart-0.9.2-py3-none-any.whl.

File metadata

  • Download URL: pymc_bart-0.9.2-py3-none-any.whl
  • Upload date:
  • Size: 31.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for pymc_bart-0.9.2-py3-none-any.whl
Algorithm Hash digest
SHA256 dacda5dc22a229c973aca13bc007318d016382373d191842e0ebc4d6cc6dc2f2
MD5 10b7b05b4d961e47300abaabbe1e6f05
BLAKE2b-256 0c689317f580d73718fe03823a8221d71f093266e4fb284423e8d0c8ceb52653

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page