Read The Times Australia

Daily Bulletin

Explainer: how the internet knows if you're happy or sad

  • Written by: Lewis Mitchell, Lecturer in Applied Mathematics, University of Adelaide

Think about what you shared with your friends on Facebook today. Was it feelings of “stress” or “failure”, or perhaps “joy”, “love” or “excitement”? Each time we post on social media, we leave traces of our mood.

Our emotions are valuable commodities, and many companies are developing automated tools to recognise them in a process known as sentiment analysis.

Recently, a leaked report revealed that Facebook can identify when young people are feeling vulnerable, although the company has insisted it did not use the analysis to target users with advertising. Facebook also apologised in 2014 for an experiment on “emotional contagion” in which posts with either “positive” or “negative” sentiment were filtered from users’ feeds.

Clearly, the ability to detect emotion from text is of great interest to social media companies, as well as advertisers. But how does sentiment analysis work, why is it useful and what are the dangers?

How does sentiment analysis work?

While the details of Facebook’s own algorithm are not publicly known, most sentiment analysis techniques fall into two categories: supervised or unsupervised.

Supervised methods rely on labelled data. In other words, these are posts that have been classified manually as containing positive or negative sentiment.

Statistical methods are then used to train models to classify new posts automatically based on the presence of pre-identified words or phrases, for example “stressed” or “relaxed”.

Unsupervised methods, on the other hand, often rely on building a dictionary of scores for different words. One such dictionary developed by my collaborators asked people to give a 1 to 9 happiness score to different words, and then averaged the results: “rainbows”, for example, scored 8.06, while “useless” gets 2.52.

The overall sentiment of a phrase can then be scored by looking at all the words in the post. For example, the average score for the post “My momma always said ‘life is like a box of chocolates’” is an above-average 6.02 according to this dictionary, suggesting it expresses a positive feeling.

What is sentiment analysis used for?

Sentiment analysis is increasingly used by marketers to study trends and make product recommendations.

Imagine a new mobile phone is released; a sentiment analysis of social media posts about the phone may give a company valuable, real-time insight into how it’s performing.

There are broader applications of sentiment analysis. Researchers have recently tracked Donald Trump’s Twitter sentiment over the first 100 days of his presidency and built bots to place market trades when he tweets positively or negatively about specific companies.

Scientists can track emotional trends in other texts as well. For example, we used sentiment analysis to study the emotional arcs of more than 1,000 films through their screenplays. The arc of the 2013 Disney film Frozen is shown below.

image Emotional arc for the movie Frozen.

Many films show similar patterns: regular peaks and troughs of tension and release, followed by a particularly big trough 80% of the way through the film (all hope is lost!), before the final resolution and happy ending. Applying a similar analysis to novels, we showed that most stories follow one of six basic story arcs.

We’re still not that good at sentiment analysis

Given that sentiment analysis often relies on mining social media posts, it raises major ethical concerns, and this debate is only beginnning. Yet the complex nature of language and meaning makes it prone to error.

Take the phrase, “May the force be with you”, which scores 5.35 using our dictionary’s analysis. For any Star Wars fan, it is of course a hugely positive phrase, but it scored modestly in our test because the word “force” is rated a below-average 4.0.

This is understandable when rating this word in isolation, but in context it makes less sense.

Some scepticism of the validity of Facebook’s sentiment analysis capabilities is therefore warranted. It’s entirely conceivable that describing something as “fully sick” on Facebook, a phrase of colloquial endorsement, could lead to an individual’s emotional state being misclassified.

To understand when sentiment analysis does and doesn’t work, it is important to examine the words that drive particular results.

To do this, we use “word shift” diagrams, like the one below for Frozen. This shows which words made the climax of the screenplay sadder than its happy ending: more references to “sadness” and “fear”, but strangely, more “beautiful”.

image Plot comparing the climax of Frozen to its happy ending. The blue bars towards the top of the chart show the top contributing words to the difference in score.

Promise and a warning

Sentiment analysis is a powerful tool, but it’s only a young science and must be used with caution.

Scientists must develop tools that allow us to peer “under the hood” and understand why certain algorithms produce the results they do. This is the only way to diagnose issues with different methods, and more importantly, to educate the public about the field’s possibilities and limitations.

Sentiment analysis research has largely been built on large, public data sets, particularly from social media. It’s important those of us unwittingly providing the data understand what it can and can’t be used for, and how.

Michelle Edwards contributed to this article.

Authors: Lewis Mitchell, Lecturer in Applied Mathematics, University of Adelaide

Read more http://theconversation.com/explainer-how-the-internet-knows-if-youre-happy-or-sad-77401

Business News

How Telematics Helps Australian Companies Improve Productivity

Operating a commercial fleet in Australia is a uniquely demanding endeavour. Between the sprawling urban sprawl of cities like Sydney and Melbourne and the immense, unforgiving stretches of the Outb...

Daily Bulletin - avatar Daily Bulletin

Inside the Icon: The BridgeMuseum Officially Opens at the Sydney Harbour Bridge

A bold new way to experience one of Australia’s most recognisable landmarks has arrived, with BridgeClimb Sydney officially opening the all-new BridgeMuseum.  Located inside the Sydney Harbour Brid...

Daily Bulletin - avatar Daily Bulletin

Is Your Brand Showing Up in AI Search? Most Melbourne Brands Aren't.

The New Front Door Nobody Told You About Something changed. Quietly. Without a press release. The way buyers find businesses in Australia has been rewired. Not replaced, rewired. Google isn't dead...

Daily Bulletin - avatar Daily Bulletin

How Australian Businesses Can Measure SEO ROI

SEO can feel vague when you are staring at a dashboard full of numbers that do not clearly connect to revenue. The key is to measure the right signals in the right order, then tie them back to outcome...

Daily Bulletin - avatar Daily Bulletin

How Commercial Roller Shutters Improve Site Security Without Slowing Operations

Security upgrades can be frustrating when they make everyday work harder. A door that takes too long to open, creates bottlenecks at shift change, or fails at the worst time can turn “better protectio...

Daily Bulletin - avatar Daily Bulletin

Why a Document Destruction Service Still Matters for Modern Businesses

Businesses generate large volumes of information every day, from staff records and contracts to invoices, reports and customer files. While attention often focuses on how documents are stored, the way...

Daily Bulletin - avatar Daily Bulletin

Bicycle Rack Safety and Space-Smart Storage

Bike storage problems usually show up as small annoyances first: tangled handlebars, scratched frames, and bikes that topple when you pull one out. Over time, those issues become safety risks, especia...

Daily Bulletin - avatar Daily Bulletin

How to Tell if a Childcare Centre Is a Good Fit for Your Child

Choosing childcare can feel like you’re making a huge decision with limited information. Tours are short, centres are often on their best behaviour, and your child might act differently in a new space...

Daily Bulletin - avatar Daily Bulletin

Car Import Timeline: What Usually Happens at Each Stage

Importing a car into Australia can feel confusing because multiple agencies and checkpoints are involved, and the timeline is shaped as much by paperwork quality as it is by shipping speed. The most u...

Daily Bulletin - avatar Daily Bulletin

The Daily Magazine

Gold Migration Lawyers in Liquidation: How the Closure Affects Your ART Appeal

If your appeal was with Gold Migration Lawyers, a recent change to how the Tribunal decides cases ...

The pressure cooker: life in urban Australia in 2026

Australian cities have always been demanding. Long commutes, rising housing costs, busy schedules a...

What Actually Makes a Good Criminal Lawyer in Melbourne

Most people only think about this question once. That is usually too late. Most people charged wi...

Why Working With A Chatswood Tutor Can Improve Academic Performance

Academic expectations continue increasing for students across primary school, high school, and senio...

Is It Worth Getting Solar Panels in Melbourne?

The real question is not whether solar works in Melbourne. It works. The question is what it is co...

How A Diploma Of Project Management Builds Practical Skills For Modern Work Environments

Developing the ability to plan, execute, and deliver outcomes efficiently is a key requirement in to...

How to Choose the Right Football for Every Level

Choosing a football may seem straightforward, but the right option depends on who will be using it a...

What to Ask a Wedding Photographer Before You Book

Booking a wedding photographer can feel deceptively simple: you like the photos, you like the vibe...

Why Stress Relief For Dogs Is Essential For Emotional Balance And Long-Term Wellbeing

Managing emotional health is just as important as physical care when it comes to pets, which is why ...