Skip to main content

BN testing

Test Package Documentation Status PyPI

A test framework to evaluate methods that learn Bayesian Networks from high-dimensional observational data.

Sampling

Set up the graphical model and sample data

from bn_testing.models import BayesianNetwork
from bn_testing.dags import ErdosReny
from bn_testing.conditionals import PolynomialConditional


model = BayesianNetwork(
   dag=ErdosReny(p=0.01, n_nodes=100),
   conditionals=PolynomialConditional(max_terms=5)
)

df = model.sample(10000, normalize=True)

The observations are stored in a pandas.DataFrame where the columns are the nodes of the DAG and each row is an observation. The underlying DAG of the graphical model can be accessed with model.dag

Metadata

Release files for bn-testing 0.12.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for bn-testing 0.12.2
File Size Uploaded
bn_testing-0.12.2.tar.gz 13.7 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for bn-testing 0.12.2
File Interpreter ABI Platform
bn_testing-0.12.2-py3-none-any.whl Python 3 none any Details

Total release size: 28.5 kB

Release files / bn_testing-0.12.2.tar.gz

Download URL bn_testing-0.12.2.tar.gz
Size 13.7 kB
Tags Source
SHA-256 checksum
How to use checksums
cbeed23c5a93a11f4b35832ca30af2d61ee45004347c60a73f16d94ff99cd96f
BLAKE2b-256 checksum
How to use checksums
8f09b540a7c48b061552232bd26af396efa8ec0b3ad1b929765f48196eb8b609
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.11.4

Release files / bn_testing-0.12.2-py3-none-any.whl

Download URL bn_testing-0.12.2-py3-none-any.whl
Size 14.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
e1b1bdc33f888cfd125918e498689e1039aef53443488c13bcc304d8d30304c0
BLAKE2b-256 checksum
How to use checksums
13702c16156ceb6431814e54d59647a20d003b60c7e51f51fbccce8bfb11ce29
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.11.4

Release history Release notifications | RSS feed

This release

0.12.2 This release

2 release files

0.10.1

2 release files

0.10.0

2 release files

0.9.0

2 release files

0.8.1

2 release files

0.8.0

2 release files

0.7.2

2 release files

0.7.1

2 release files

0.7.0

2 release files

0.6.0

2 release files

0.5.0

2 release files

0.4.2

2 release files

0.4.1

2 release files

0.4.0

2 release files

0.3.3

2 release files

0.3.2

2 release files

0.3.1

2 release files

0.3.0

2 release files

0.2.0

2 release files

0.1.1

3 release files

0.1.0

2 release files

0.0.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page