as_named_vector {dbnR} | R Documentation |
Converts a single row data.table into a named vector
Description
Given a single row data.table, convert it into a named vector. Used in the mvn_inference, to obtain an evidence named vector. For this case, the data.table should contain only the evidence that we want to provide. If a named vector is provided instead of a data.table, nothing will be done and the named vector will be returned.
Usage
as_named_vector(dt)
Arguments
dt |
a 1 row data.table or a named vector |
Value
a named vector with the values and the variable names
[Package dbnR version 0.7.9 Index]