NaiveBayes probability calculation and model creation code written.