A causal graphical model needs numerical parameters for its probability distributions. Maximum likelihood estimation (MLE) chooses the parameter values under which the observed training data are most likely. Likelihood asks how probable the data would be for a candidate parameter value; it does not, by itself, establish that the model represents the true data-generating process. section 2.3.4 section 2.5
For data D and parameters θ, the objective is to maximize P(D | θ). Implementations usually maximize log P(D | θ) instead: it has the same maximizer and is easier to work with mathematically and computationally. Equivalently, minimizing negative log-likelihood is a loss-minimization problem. Some estimates have a mathematical solution, as in certain linear regression models; others require numerical optimization. For neural networks, optimization may find a high-likelihood candidate rather than the maximum. section 2.3.4
Fit a conditional probability table
With categorical data, MLE reduces to proportions of counts. To estimate P(O=emp | E=high), divide the number of records with both O=emp and E=high by the number with E=high. In pgmpy, BayesianNetwork.fit(data) uses MLE as its default parameter-learning method; no estimator argument is needed. section 3.1.9
MLE is one choice within a broader parameter-learning workflow. L2 regularization changes the loss to discourage very large estimates. Bayesian estimation instead places a prior distribution on parameters and infers from both that prior and the data. These choices should not be confused with determining whether the model’s causal assumptions are sound. section 2.3.4 section 2.5



