Learn R Programming

MoTBFs (version 2.0)

print.motbf: Print object of class motbf print method for class "motbf".

Description

Print object of class motbf print method for class "motbf".

Print a single node of a BN. This function is called by print.motbf_fit, but not exported.

Print the results of a k-fold cross validation

Usage

# S3 method for motbf
print(x, ...)

# S3 method for motbf_fit print(x, ...)

# S3 method for motbf.fit.node print(x, ...)

# S3 method for motbf_fit_cv print(x, ...)

# S3 method for univmotbf print(x, ...)

# S3 method for piecewisemop print(x, ...)

# S3 method for jointmotbf print(x, ...)

Arguments

x

An object of class "motbf", "motbf_fit", "univmotbf", "piecewisemop", "jointmotbf", or "motbf.fit.cv".

...

optional arguments passed to print for other classes created in the MoTBFs package. Currently, no optional arguments are supported.

Details

The following classes are created in the MoTBFs package:

motbf

the generic class common to all objects created in the package

univmotbf

the class corresponding to MTE or MOP univariate distributions. An object of class univmotbf is the output of function univMoTBF().

piecewisemop

the class corresponding to MOP univariate distributions defined by multiple sub-functions with different domain. When calling variableElimination(), the output might be of this class.

jointmotbf

the class corresponding to joint distributions. An object of class jointmotbf is the output of function jointMOP()

motbf_fit

the class corresponding to fully fitted Bayesian network models (either discrete, continuous or hybrid). An object of class motbf_fit is the output of function motbf.fit().

motbf.fit.cv

the class corresponding to k-fold cross validation results. An object of class motbf.fit.cv is the output of function motbf.cv().

motbf.fit.node

the class corresponding to a single node of a Bayesian Network.

Examples

Run this code
# \donttest{
## Dataset Ecoli
data(ecoli)
data <- ecoli[,-c(1)] ## remove variable sequence

## Directed acyclic graph
dag <- LearningHC(data)

## Learning BN
P <- motbf.fit(graph = dag, data = data, numIntervals = 3, POTENTIAL_TYPE = "MOP",
maxParam = 15)
P
# }

Run the code above in your browser using DataLab