configs {bnlearn} R Documentation

Construct configurations of discrete variables

Description

Create configurations of discrete variables, which are used in modelling conditional probability tables.

Usage

  configs(data, all = TRUE)

Arguments

data

a data frame containing factor columns.

all

a boolean value. If TRUE, all configurations are included as levels in the return value. Otherwise, only configurations that are actually observed are considered.

Value

A factor with one element for each row of data, and levels as specified by all.

Author(s)

Marco Scutari

Examples

data(learning.test)
configs(learning.test, all = TRUE)
configs(learning.test, all = FALSE)

[Package bnlearn version 5.2-20260704 Index]