Struct rusty_machine::learning::naive_bayes::Multinomial
[−]
[src]
pub struct Multinomial { /* fields omitted */ }
The Multinomial Naive Bayes model distribution.
Defines:
p(x|Ck) ∝ ∏i pkxi
Methods
impl Multinomial
[src]
fn log_probs(&self) -> &Matrix<f64>
The log probability matrix.
A matrix of class by feature model log-probabilities.
Trait Implementations
impl Debug for Multinomial
[src]
impl Distribution for Multinomial
[src]
fn from_model_params(class_count: usize, features: usize) -> Multinomial
Initialize the distribution parameters.
fn update_params(&mut self,
data: &Matrix<f64>,
class: usize)
-> LearningResult<()>
data: &Matrix<f64>,
class: usize)
-> LearningResult<()>
Updates the distribution parameters.
fn joint_log_lik(&self,
data: &Matrix<f64>,
class_prior: &[f64])
-> LearningResult<Matrix<f64>>
data: &Matrix<f64>,
class_prior: &[f64])
-> LearningResult<Matrix<f64>>
Compute the joint log likelihood of the data. Read more