I want to learn a Naive Bayes model for a problem where the class is boolean (takes on one of two values). Some of the features are boolean, but other features are categorical a
CategoricalNB
by scikit-learn is a new class to be added in the naive_bayes module. It's in the nightly build here.
Mixed Naive Bayes (https://github.com/remykarem/mixed-naive-bayes). It can assume a mix of Gaussian and categorical (multinoulli) distributions on the training data features. The library is written such that the APIs are similar to scikit-learn's.
from mixed_naive_bayes import MixedNB
X = [[0, 0],
[1, 1],
[2, 1],
[1, 1],
[0, 2]]
y = [0, 0, 1, 1, 0]
clf = MixedNB(categorical_features='all')
clf.fit(X,y)
clf.predict(X)
See my response in a similar question here https://stackoverflow.com/a/58428035/4570466.