Resumo: | In this dissertation, we discuss how Twitter can help detecting public sentiment towards companies listed in the stock market, in particular listed in the S&P 500 index (S&P 500). The collection of data is done through a web scrapper that collects tweets from Twitter, using advanced search features based on queries related to the companies under scrutiny. The content of tweets are classified as positive, neutral or negative sentiments and the outcome is then compared against stock market prices. To do so, it is proposed and implemented a framework with different Sentiment Analysis (SA) models and Machine Learning (ML) techniques. Also, to establish which models are more appropriate in detecting and classifying sentiments, a series of visual representations were created to evaluate and compare results. As a conclusion, the results obtained show that an increase in the volume of tweets leads to oscillations in both stock price and trading volume. Furthermore, the data analysis performed in relation to some companies under scope shows that the use of moving averages of sentiment scores makes the analysis clearer and more insightful, which is particular useful when measuring the strength or weakness of the price of a stock. In the end, it can be perceived as a momentum indicator for the stock market.
|