Sentiment analysis refers to the use of natural language processing, text analysis and computational linguistics to identify and extract subjective information in source materials. From Wikipedia
How the polarity function works
Polarity assignment, a form of sentiment analysis, uses an algorithm to determine the polarity of a sentence/statement. The polarity score generated by the polarity function used in this app is dependent upon the word polarity dictionary used by Hu & Liu (2004). From qdap package vignette