Pain and Yawn: New Behavioral Metrics in Facial Expression Analysis

iMotions introduces two new facial expression metrics, Pain and Yawn, available in iMotions Lab, iMotions Online and through the Affectiva SDK. Built to measure observable facial behavior in real time, these metrics expand opportunities for media testing, UX research, gaming, and behavioral studies. The Pain metric is also backed by dedicated scientific validation.

Two new real-time behavioral metrics, Pain and Yawn, are now available in both the Facial Expression Analysis module in iMotions Lab, iMotions Online and through the Affectiva SDK. The new metrics expand the range of facial behaviors that researchers and developers can measure, providing more detailed insights into how people respond to content, experiences, and physical stimuli.

Both metrics focus on observable facial movements rather than making broad assumptions about emotional states. They provide measurable signals that researchers and developers can interpret within the context of their particular study or application.

The new metrics are available in:

  • Affectiva SDK: For developers integrating real-time facial expression measurement into their own applications.
  • iMotions Lab: Through the Facial Expression Analysis module, allowing researchers to analyze facial behavior alongside eye tracking, GSR, ECG, surveys, and other measurements.
  • iMotions Online: The Pain and Yawn metrics will be available in the Behavioral Research Online platform in iMotions Online, allowing users to study pain and yawn in remote respondents.
Pain Metric

Introducing the Pain Metric

The new Pain metric measures pain-related facial expressions frame by frame, producing a score from 0 (no expressed pain) to 100 (intense expressed pain).

Built on an established scientific framework

The metric is based on the Prkachin and Solomon Pain Intensity (PSPI) scale, an established framework for quantifying facial expressions associated with pain.

It measures specific facial movements, including brow lowering, tightening around the eyes, nose wrinkling, and eye closure. Together, these movements provide a quantifiable indication of how strongly pain-related facial behavior is expressed.

Beyond experimental pain research, these expressions may also occur during intense or uncomfortable experiences, making the metric relevant to research involving dramatic media, immersive environments, and interactive content.

Validated through controlled pain research

To evaluate the performance of the new metric, iMotions researchers conducted a validation study involving 38 participants and two established experimental pain models: the Cold Pressor Test, in which participants immerse a hand in ice-cold water, and exercise-induced muscle soreness.

The metric achieved a ROC-AUC of 96.1% when evaluated against manually coded ground truth, demonstrating strong discrimination performance in the validation study. The results provide a scientific foundation for using the metric to quantify pain-related facial expressions in research settings.

Read the full study:

An important distinction: Pain is not always visible

One of the study’s findings highlights why facial expression analysis should be interpreted within a broader research context.

Approximately half of the participants showed no observable facial expressions of pain, despite reporting pain levels similar to those who did.

This means that a low Pain score should not be interpreted as an absence of pain. It simply indicates that pain-related facial expressions were not detected.

For researchers using iMotions Lab, the metric can be combined with physiological measurements such as heart rate and GSR, both of which showed responses to pain even among participants who did not visibly express it. Researchers can also adjust the detection threshold to suit the sensitivity requirements of their studies.

Applications for researchers and developers

For developers working with the Affectiva SDK, the Pain metric offers a way to identify moments of pronounced pain-related facial behavior during gameplay, video content, advertising, and other interactive experiences.

For researchers using iMotions Lab, potential applications include occupational health, ergonomics, human factors, sports science, and telehealth research.

The Pain metric is intended for research purposes and is not a clinical or diagnostic device.

Also Available in iMotions Online

The new Pain and Yawn metrics are also available in iMotions Online through Behavioral Research Online, allowing researchers to measure these facial expressions remotely using participants’ webcams. This makes it possible to incorporate the metrics into online studies, alongside other behavioral measurements, without requiring participants to visit a physical lab.

Pain and Yawn Metric

Introducing the Yawn Metric

Alongside Pain, the new Yawn metric detects and measures yawning behavior in real time, expanding facial expression analysis into another area of observable human behavior.

While earlier yawn detection models were developed primarily for driver monitoring, the new metric is designed for broader applications, including media testing, gaming, e-learning, and digital experience research.

Measuring yawning rather than assuming fatigue

Yawning is frequently associated with tiredness, boredom, and changes in alertness, but its occurrence does not necessarily indicate any one of these states.

The Yawn metric therefore focuses on detecting the physical expression itself, including characteristic mouth opening and jaw movement, rather than assigning an emotional or cognitive interpretation.

The model was trained using diverse real-world viewing data from Affectiva’s Media Analytics platform, reflecting variations in participants and recording environments.

Designed for low-latency processing, the metric can support live and interactive applications. It also incorporates filtering to distinguish yawning behavior from shorter mouth movements that might otherwise produce false detections.

Applications in media and behavioral research

For media testing and advertising research, Yawn provides an additional behavioral signal that can be examined alongside audience responses to particular scenes, messages, or creative elements.

In gaming, e-learning, and UX research, it can help researchers investigate patterns of yawning during longer interactions or sustained tasks, particularly when combined with other behavioral and physiological measurements.

Rather than treating yawning as a direct measure of boredom or disengagement, researchers can use it as one additional observation when investigating how experiences unfold over time.

Expanding the Possibilities of Facial Expression Analysis

With the addition of Pain and Yawn, Affectiva’s facial expression analysis capabilities now include two further metrics focused on specific, observable behaviors.

For developers, the new metrics provide additional signals that can be integrated into real-time applications through the Affectiva SDK. For researchers using iMotions Lab, they offer new opportunities to investigate facial behavior alongside eye tracking, physiological measurements, and other research data.

Together, they support a more detailed understanding of what people visibly express, while leaving the interpretation of those expressions where it belongs: within the context of the research.

Free 42-page Facial Expression Analysis Guide

For Beginners and Intermediates

  • Get a thorough understanding of all aspects
  • Valuable facial expression analysis insights
  • Learn how to take your research to the next level

Get Richer Data

About the author


See what is next in human behavior research

Follow our newsletter to get the latest insights and events send to your inbox.