Skip to main content
Join the official 2020 Python Developers SurveyStart the survey!

Manipulate Bayesian Networks of Continuous Random Variables

Project description

curv (Continuous Random Variables) is a python package for creating and manipulating continuous random variables in a bayesian network. You may find it useful for performing bayesian inference on “broad” distributions with high kurtosis or highly dimensional joint distributions where discrete sampling would require excessive memory.

Typical usage often looks like this:

   #!/usr/bin/env python

   import curv as cv

   A = cv.Normal(1,2)
   B = cv.Uniform(-5,4)
   C = 4 + A - 2*B
   D = C * A**2
   A = cv.Normal(1,1)

**Table of Contents**
  • [Installation & Dependencies](#)
  • [Usage](#)
    • [Creating a Bayesian Network](#)
    • [Performing Inference](#)
    • [Displaying Results](#)
  • [Under the Hood](#)
    • [Characteristic Functions](#)
    • [Joint Probability Characteristic Functions](#)
    • [Computing and Plotting Results](#)
    • [Bayesian Inference](#)

Installation & Dependencies

Dependencies include:

  • Numpy
  • Scipy
  • Matplotlib


Curv stores its random variables as continuous functions as opposed to storing discrete probabilities in sampled bins. This data structure reduces memory consumption (since distributions are not sampled and stored as individual points).

As a result, curv would be useful for handling large, highly dependent bayesian networks with high dimensional joint probability distribution functions without second-order approxiations (such as Chow-Liu trees).

Curv would also be useful for distributions with high kurtosis, where discrete sampling over a large number of bins would be needed to capture rare events at the edges of the distribution.

Creating a Bayesian Network

Performing Inference

Displaying Results

Under the Hood

Characteristic Functions

Joint Probability Characteristic Functions

Computing and Plotting Results

Bayesian Inference

Project details

Release history Release notifications | RSS feed

This version


Download files

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

Files for curv, version 0.1
Filename, size File type Python version Upload date Hashes
Filename, size curv-0.1-py3-none-any.whl (5.5 kB) File type Wheel Python version py3 Upload date Hashes View
Filename, size curv-0.1.tar.gz (3.9 kB) File type Source Python version None Upload date Hashes View

Supported by

Pingdom Pingdom Monitoring Google Google Object Storage and Download Analytics Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page