class_docstr: Gaussian Naive Bayes.
  
  A Gaussian distribution $G_{cf}$ is maintained for each class $c$ and each feature $f$. Each
  Gaussian is updated using the amount associated with each feature; the details can be be found
  in `proba.Gaussian`. The joint log-likelihood is then obtained by summing the log probabilities
  of each feature associated with each class.
  
  Examples
  --------
  
  >>> from river import naive_bayes
  >>> from river import stream
  >>> import numpy as np
  
  >>> X = np.array([[-1, -1], [-2, -1], [-3, -2], [1, 1], [2, 1], [3, 2]])
  >>> Y = np.array([1, 1, 1, 2, 2, 2])
  
  >>> model = naive_bayes.GaussianNB()
  
  >>> for x, y in stream.iter_array(X, Y):
  ...     model.learn_one(x, y)
  
  >>> model.predict_one({0: -0.8, 1: -1})
  1
class_docstr_tok: ["Gaussian","Naive","Bayes",".","A","Gaussian","distribution","$","G_","{","cf","}","$","is","maintained","for","each","class","$","c","$","and","each","feature","$","f","$",".","Each","Gaussian","is","updated","using","the","amount","associated","with","each","feature",";","the","details","can","be","be","found","in","`","proba.Gaussian","`",".","The","joint","log-likelihood","is","then","obtained","by","summing","the","log","probabilities","of","each","feature","associated","with","each","class",".","Examples","--","--","--","--",">",">",">","from","river","import","naive_bayes",">",">",">","from","river","import","stream",">",">",">","import","numpy","as","np",">",">",">","X","=","np.array","(","[","[","-1",",","-1","]",",","[","-2",",","-1","]",",","[","-3",",","-2","]",",","[","1",",","1","]",",","[","2",",","1","]",",","[","3",",","2","]","]",")",">",">",">","Y","=","np.array","(","[","1",",","1",",","1",",","2",",","2",",","2","]",")",">",">",">","model","=","naive_bayes.GaussianNB","(",")",">",">",">","for","x",",","y","in","stream.iter_array","(","X",",","Y",")",":","...","model.learn_one","(","x",",","y",")",">",">",">","model.predict_one","(","{","0",":","-0.8",",","1",":","-1","}",")","1"]
docstr: Return probabilities using the log-likelihoods.
docstr_tok: ["Return","probabilities","using","the","log-likelihoods","."]
code: def predict_proba_one(self, x):
      """Return probabilities using the log-likelihoods."""
      jll = self.joint_log_likelihood(x)
      if not jll:
          return {}
      lse = special.logsumexp(list(jll.values()))
      return {label: math.exp(ll - lse) for label, ll in jll.items()}
  
file_path: river/river/naive_bayes/gaussian.py
imports: from __future__ import annotations
  import collections
  import functools
  import math
  import pandas
  from scipy import special
  from river import base, proba
label_desc: Use image node_id 3 for calling the GaussianNB obj's underlying member method code with example usage: obj.predict_proba_one(x) and returns: unknown, dict