/ machine learning

What is Sentiment Analysis?

Synopsis

Sentiment analysis is the automated process of interpreting opinion from any piece of text. In this post, we quickly walk-through sentiment analysis using two simple examples. We also provide a list of some applications of sentiment analysis that are commonly used in our day-to-day lives.

Introduction

Milton recently launched a Smart Watchlist. One of the most popular features on the Smart Watchlist is news powered by artificial intelligence. Milton reads most financial news published on any given day. We present Milton's Sentiment Score for every news article for you on every stock on your Milton Smart Watchlist. But how does a computer know whether a news article is positive, negative, or neutral?

The short answer is by using sentiment analysis. Sentiment analysis is the process of taking text data and deriving value from it using data mining and natural language processing (NLP) techniques. While there are different machine learning algorithms to do this, we will explore lexicon and rules-based sentiment analysis for this post.

This particular method looks at the structure of the words in a sentence or paragraph, the words used and how they are presented. From this, we can derive a quantitative score that represents the sentiment of a sentence, or in the case of Milton, the sentiment of an article.

A Simple Example

Let's compare the sentiment scores for two very simple sentences using a scale of -1 to +1. On this scale, -1 is extremely negative, 0 is neutral, and 1 is extremely positive.

Let's take the following two sentences:

  1. The stock market SUCKS!!!
  2. The stock market kinda sucks, but I'll get by :-)

Obviously, these statements are similar. But from the perspective of our algorithm, the scores couldn't be more different. For example, sentence #1 has a sentiment score of -0.56 versus sentence #2 having a sentiment score of +0.56, marking a significant contrast as to how Milton would interpret these sentences in the context of reading a financial news article.

Why is this? Simple and obvious nuances, like the capitalization of the word "sucks" in sentence #1, the existence of exclamation points in sentence #1 versus no exclamation points in sentence #2, the use of a modifier "kinda" in sentence #2 versus no modifier in sentence #1, and the additional text in sentence #2 "but I'll get by", and even the existence of a positive emoji ":-)", provides sufficient enough contrast between these two statements. Milton is able to detect these patterns due to advancements in natural language processing that we employ when developing data-driven insights for you.

An Example From Milton: Facebook News

Let's use the same exercise on two pieces of financial news from Milton's perspective. Below is a screen shot below for two articles that Milton read about Facebook (ticker: FB) on November 16, 2018.

Example: Two Articles Read By Milton On November 16, 2018

If you were to read the two articles above, you learn the following:

1) The top article has a sentiment score of 90. This is considered very positive as seen by the green bar above. A few takeaways from reading the article:

(+) The opinion of JP Morgan's internet analyst matters to Wall Street and he is bullish on Facebook into 2019.

(+) The Analyst believes Facebook's user activity has stabilized.

(+) The Analyst believes the company is making the appropriate investments and supportive of CEO Mark Zuckerberg.

2) The bottom article has a sentiment score 10. This is considered very negative as seen by the red bar above. A few takeaways from reading this article:

(-) Consumers broadly mistrust Facebook amid Russian hacking during the 2016 US Presidential election.

(-) Facebook management's handling of Russian hacking was slow and controversial.

(-) A theme of uncertainty around Facebook's future given its well-publicized internal and external issues.

Sentiment Analysis Used All Around Us

Whether you know it or not, you encounter sentiment analytics every day. Here are a few widely used applications:

  • Customer service: call centers can detect things like the change in the amount of stress or tension in a customer's voice, measure their rate of speech, and other objective measurements to determine if a customer is happy or not.
  • Monitoring social media: social media is widely used by companies to monitor customer satisfaction. For example, companies like United Airlines (ticker: UAL) can monitor delays and measure customer satisfaction with their travel.
  • Reputation analysis: How does a large consumer products company like Proctor & Gamble (PG) or McDonald's (MCD) determine if someone likes a new product.
  • Product recommendations: Aggregating product reviews across large commerce websites such as Amazon (AMZN) or Walmart (WMT) to determine the best product to buy.
  • Employee happiness: Using surveys or aggregated reviews of employee reviews from Glassdoor to determine if a company is a good place to work.

Conclusion

We are excited to include AI-powered news on Milton's Smart Watchlist to help you save time by reading the most important news for the companies you track, and being able to objectively measure whether that news is positive, negative, or neutral.

We will be introducing lots of cool new features on Milton's Smart Watchlist related to sentiment, and we even recently launched a daily e-mail recap that aggregates the most important news for you every morning, on every ticker on your Smart Watchlist. So don't forget to login to Milton and setup your Watchlist free.

For more reading on how to use the algorithm we talked about today checkout: https://github.com/cjhutto/vaderSentiment


About Apteo
Apteo, the company behind Milton, is made up of curious data scientists, engineers, and financial analysts based in the Flatiron neighborhood in New York City.  We have a passion for technology and investing, and we strongly believe that investing is one of the most reliable and effective ways to build long-term wealth.  We build AI tools to help informed investors make better decisions.  

To learn more about us, please reach out to us at info@apteo.co, join our mailing list at milton.ai, or subscribe to Milton’s blog at blog.milton.ai.


Disclaimer
Apteo, Inc. is not an investment advisor and makes no representation or recommendation regarding investment in any fund or investment vehicle.

What is Sentiment Analysis?
Share this

Subscribe to Milton's Blog