powered by
Auxiliary function for "naive_bayes" and "*_naive_bayes" objects for easy browsing tables.
"naive_bayes"
"*_naive_bayes"
tables(object, which = NULL)
list with tables.
object of class inheriting from: "naive_bayes" and "*_naive_bayes".
tables to be showed (all by default). This can be any valid indexing vector or vector containing names of variables.
Michal Majka, michalmajka@hotmail.com
Default print method for "naive_bayes" and "*_naive_bayes" objects shows at most five first tables. This auxiliary function tables returns by default all tables and allows easy subsetting via indexing variables.
tables
naive_bayes, bernoulli_naive_bayes, multinomial_naive_bayes, poisson_naive_bayes, gaussian_naive_bayes, tables, get_cond_dist
naive_bayes
bernoulli_naive_bayes
multinomial_naive_bayes
poisson_naive_bayes
gaussian_naive_bayes
get_cond_dist
data(iris) nb <- naive_bayes(Species ~ ., data = iris) tables(nb, "Sepal.Length") tables(nb, c("Sepal.Length", "Sepal.Width")) tabs <- tables(nb, 1:2) tabs tabs[1]
Run the code above in your browser using DataLab