Learn R Programming

sparsebnUtils (version 0.0.8)

estimate.parameters: Estimate the parameters of a Bayesian network

Description

Given the structure of a Bayesian network, estimate the parameters (weights) using ordinary least squares (for Gaussian data) or logistic regression (for discrete data).

Usage

estimate.parameters(fit, data, ...)

Arguments

fit

fitted sparsebnFit or sparsebnPath object containing the Bayesian network structure to fit.

data

Data to use for fitting.

...

(optional) additional arguments to pass to lm or glm.

Details

The low-level fitting methods are fit_glm_dag (for continuous data) and fit_multinom_dag (for discrete data).