A sentiment analysis of a Kenyan bank using tweets. The tweets were sourced using the Twitter API and tweepy, a python library for accessing the twitter API.
- Irrelevant tweets accounted for the larger percentage, these are tweets meant for advertisement purposes and were not specifically directed at the bank.
- Negative tweets were the second larget group
- Requests and inquiries came third, these are tweets requesting the bank admin to respond or questions regarding the banks services.
- Positive tweets came last with suggestions which I had to exclude from the analysis as the model would not take in a category with only one observation.
The comparison was quite large , with positive tweets not amounting to even half of the negative tweets
Objective 3: To train the sentiment analysis model to classify tweets as either irrelevant, negative, positive or inquiry/request
Used Sklearn's train_test_split to train the models
Model 2: Using SVM(Support vector machines): Achieved an accuracy of 66.7%, a little lower than Multinomial NB
Used RegEx to search for the bank's popular services such as the mobile banking app, online banking , customer service e.t.c