R scripts for calculating sentiment analysis