Reference Manual: DSL pc

From DSL

Jump to: navigation, search

This class implements the PC algorithm for learning the structure and parameters of a Bayesian network.

Fields

Below is a list of fields of this class that allow for specifying the details of the learning algorithm.

int maxAdjacency, maximum adjacency size, default = 8.

double significance, the significance level, default = 0.05.

IntPairVector forcedArcs, vector of pairs of indices (parent, child) denoting arcs that will be present in the graphical structure. Variables indices correspond to the indices of the DSL_dataset.

IntPairVector forbiddenArcs, vector of pairs of indices (parent, child) denoting arcs that will be absent in the graphical structure. Variables indices correspond to the indices of the DSL_dataset.

IntPairVector tiers, vector of pairs, where integers in the pair mean (variable, tier number). Tier numbers start from 1. Variables indices correspond to the indices of the DSL_dataset.


Methods

  • DSL_pc()

Constructor, that initializes the object with default values of parameters used for learning.


  • int Learn(const DSL_dataset &data, DSL_network &net);

This method performs actual learning procedure. The first argument is the input data set. The result of learning procedure is stored in the DSL_network which is the second argument. The method returns DSL_OKAY if the learning was successful and some error code otherwise.

Personal tools