API Reference#
Public API reference for pgmpy.
Browse by workflow or object family to find the public classes and helper functions for that part of the library.
Deprecated compatibility aliases are intentionally omitted from the main API listings in favor of the current class names.
DAG, PDAG, MAG, PAG, and other base graph structures.
Bayesian networks, SEMs, Markov models, and derived graph structures.
Discrete factors, CPDs, Gaussian CPDs, hybrid CPDs, and factor utilities.
Exact inference, approximate inference, sampling, and elimination-order helpers.
Identification, interventional inference, and regression-based causal estimators.
Estimator base classes, MLE, Bayesian estimation, EM, SEM fitting, and mirror descent.
Constraint-based, score-based, tree-based, and expert-guided discovery algorithms.
Built-in CI test selectors and test implementations.
Discrete, Gaussian, and conditional-Gaussian structure scoring classes.
Supervised and unsupervised metrics for evaluating learned graphs and fitted models.
Reader and writer classes for BIF, XMLBIF, XDSL, UAI, PomdpX, and related formats.
Built-in dataset loaders and example-model discovery helpers.
Independence assertions and collections used across discovery and testing workflows.