naive bayes script