Measuring Stress in Real-Time
Following on again from the previous posts on affective computing, this post presents what is our final solution for the cross-disciplinary project. To reiterate, our task was to research and implement a way of measuring the stress of a player. To be used and interpreted inside of a game project, adhering to the notion of affective computing through a non-standard input device. Despite a previous proposal detailing capturing of ones heart beat through subtle changes in skin colour, the project was reincarnated and the decision made to use a more appropriate device. Together with Jared Ford, we devised a solution using the Ardunio Pulse Sensor with Heart Rate Variability analysis.
Heart rate or Beats Per Minute (BPM) alone is not an accurate indicator of stress, Heart Rate Variability (HRV) is currently the best solution for determining stress levels of an individual. HRV is the variation of time between heartbeats, also known as interbeat intervals (IBI). HRV can be determined using a variety of statistical methods, each suited differently depending on the purpose and sample size available. The Root Mean Square of the Successive Differences (RMSSD) works best for short-term heart rate data, such as real-time applications with successive differences synonymous with interbeat intervals in the case of this project.
Using Unity as our development platform, our solution at a minimum consists of two scripts. One to handle retrieving of live heart rate data from the Arduino and the other to interpret that data into usable metrics. Those available are average BPM, raw RMSSD based HRV or a normalised level of stress, derived from the RMSSD confined within what is considered the normal range for healthy individuals. Two variables have been exposed for configuration of sample size and an upper RMSSD limit, used by the normalised stress algorithm for clamping. Samples are merely the successive differences, with higher counts yielding greater accuracy at the expense of real-time responsiveness within an interactive application.
Heart rate or Beats Per Minute (BPM) alone is not an accurate indicator of stress, Heart Rate Variability (HRV) is currently the best solution for determining stress levels of an individual. HRV is the variation of time between heartbeats, also known as interbeat intervals (IBI). HRV can be determined using a variety of statistical methods, each suited differently depending on the purpose and sample size available. The Root Mean Square of the Successive Differences (RMSSD) works best for short-term heart rate data, such as real-time applications with successive differences synonymous with interbeat intervals in the case of this project.
Using Unity as our development platform, our solution at a minimum consists of two scripts. One to handle retrieving of live heart rate data from the Arduino and the other to interpret that data into usable metrics. Those available are average BPM, raw RMSSD based HRV or a normalised level of stress, derived from the RMSSD confined within what is considered the normal range for healthy individuals. Two variables have been exposed for configuration of sample size and an upper RMSSD limit, used by the normalised stress algorithm for clamping. Samples are merely the successive differences, with higher counts yielding greater accuracy at the expense of real-time responsiveness within an interactive application.
Comments
Post a Comment