bayesToLatex {mmb} | R Documentation |
Create a string that can be used in Latex in an e.g. equation-environment.
Description
This function can be used to generate Latex-markup that models the full dependency between covariates and a target variable.
Usage
bayesToLatex(conditionalFeatures, targetFeature, includeValues = FALSE)
Arguments
conditionalFeatures |
data.frame of Bayesian features, the target feature depends on. |
targetFeature |
data.frame that holds exactly one Bayesian feature, that is supposed to be the target-feture for Bayesian inferencing. |
includeValues |
default FALSE boolean to indicate whether to include the features' values or not, i.e. "A" vs. "A = setosa". |
Value
a string that can be used in Latex documents.
Note
Use cat()
to print a string that can be copy-pasted.
Author(s)
Sebastian Hönel sebastian.honel@lnu.se
Examples
feat1 <- mmb::createFeatureForBayes(
name = "Petal.Length", value = mean(iris$Petal.Length))
feat2 <- mmb::createFeatureForBayes(
name = "Petal.Width", value = mean(iris$Petal.Width))
featT <- mmb::createFeatureForBayes(
name = "Species", iris[1,]$Species, isLabel = TRUE)
cat(mmb::bayesToLatex(conditionalFeatures = rbind(feat1, feat2),
targetFeature = featT, includeValues = TRUE))
[Package mmb version 0.13.3 Index]