# Textual Data Science for Logistics and Supply Chain Management
## 3 Results
### Sentiment Analysis  
Sentiment analysis is the process of extracting an author's emotional intent from the text with the goal of determining the general attitude. In the early days of natural language processing (NLP), people used word lists that contained positive words (with valence 1) and negative words (with valence \(-1\)). In other words, the valence score rates the polarity of a specific word. Then, either for each sentence or the entire document, they computed a simple polarity score wherein polarity = (number of positive words + number of negative words)/total number of words. More modern approaches, as implemented in the _qdap_ package that we used, incorporate valence shifters (negation and amplifier words), leading to the following sentiment scoring workflow:  
* The polarity function scans for positive and negative words within a subjectivity lexicon.
* Once a polarity word is found, the function creates a cluster of terms, including the four preceding and the two following words.
* Within each cluster, the polarity function looks for valence shifters, which give a weight to the polar word (amplifiers add 0.8, negators subtract 0.8). Words with  
Figure 1: Word clouds for companies A, B, and C.  
positive polarity are counted as \(1\), whereas words with negative polarity are counted as \(-1\).
* The grand total of positive, negative, amplifying, and negating words is then divided by the square root of all words in the respective passage. This helps to measure the density of key words.  
In our study, we calculated a polarity score for each sentence, which was then averaged (i.e., weighted by the sentence length) in order to get an overall text polarity for each interview. The sentiment analysis enabled us to identify and extract subjective information pertaining to the managers' responses. We were especially interested in the polarity of each interview based on words that are classified as positive, neutral, or negative. The polarity score is dependent on the dictionary used. In our study, we applied the polarity dictionary by [PERSON] and [PERSON] (2015) as implemented in the _qdapDictionaries_ package ([PERSON] and [PERSON], 2015). This dictionary consists of a list of 6779 words with assigned values of either \(1\) (positive valence) or \(-1\) (negative valence). Examples for words with positive valence are helpful, enjoyable, enthusiasm, smiling, stimulating. Examples for words with negative valence are unemployed, noise, incomprehensible, upsetting, procrasinate. For this study, we computed the polarity score on a document (i.e., interview) level, but the analysis would have also been possible on a sentence level.  
The individual interview polarity scores are shown in Table 1. The average sentiment scores at a company level are 0.40 for Company A, 0.14 for Company B, and 0.43 for Company C. Table 1 also illustrates the wide range of opinions within the specific companies. In company C, for example, the range of sentiment is between \(-0.58\) and 0.65, whereas in company C, almost all interviews are in the positive range, except for one slightly negative one with a score of \(-0.04\). Importantly, it has to be pointed out that the sentiment score heavily depends on the topics being discussed (e.g., exciting new growth strategy vs. problematic project failure). As a starting point, however, it allows for a general assessment of an interviewee's attitude toward a specific discussion topic expressed in one single score.