class_docstr: The Gaussian Naive Bayes classifier. 
class_docstr_tok: ["The","Gaussian","Naive","Bayes","classifier","."]
code: def fit(self, X, y):
      self.X, self.y = X, y
      self.classes = np.unique(y)
      self.parameters = []
      # Calculate the mean and variance of each feature for each class
      for i, c in enumerate(self.classes):
          # Only select the rows where the label equals the given class
          X_where_c = X[np.where(y == c)]
          self.parameters.append([])
          # Add the mean and variance for each feature (column)
          for col in X_where_c.T:
              parameters = {"mean": col.mean(), "var": col.var()}
              self.parameters[i].append(parameters)
  
file_path: ML-From-Scratch/mlfromscratch/supervised_learning/naive_bayes.py
imports: from __future__ import division, print_function
  import numpy
  import math
  from mlfromscratch.utils import train_test_split, normalize
  from mlfromscratch.utils import Plot, accuracy_score
label_desc: Use image node_id 1 for calling the NaiveBayes obj's underlying member method code with example usage: obj.fit(X, y) without return types