Gaussian Naive Bayes Classifier
With Continuous and Discrete or Categorical Functionality
A lean and efficient program for fitting Naive Bayes classifiers to either qualitative or quantitative data. In the latter case, a Gaussian distribution is used to compute probability densities. Some minor refactoring is planned, including addition of other distributions. The functionality for qualitative data has not yet been extensively tested.
Features
- Works with qualitative or quantitative data
- Uses matrix operations wherever possible for efficient operation
- Return predictions as either predicted classes (predict) or posterior probability densities (p_predict).
- Uses log probabilities for quantitative data.
- A scoring function that returns
- Accuracy
- Precision
- Recall
- F1
- Easily modified to compute other metrics like specificity or fall-out.
Get the code here