Code to generate sentiment score using NaiveBayesAnalyzer