Objective
The primary objective was to develop a statistical model capable of assessing stress levels based on behavioural health data collected from smartphone sensors, accommodating the reality that most users do not possess wearable technology. By leveraging the widespread availability of smartphones, this approach offers a scalable way to assess stress and its implications on health and behaviour within the general population, setting the stage for broader understanding and potential interventions.
Methodology
The Depression Anxiety Stress Scale (DASS-21) was used as a clinical screening tool for the overall assessment of the three conditions. This study analysed the results from the Stress sub-score of the questionnaire. All participants installed the Sahha research app, which collected and analysed digital health data from smartphone sensors and any other wearables. Participants were prompted with the DASS-21 screening questionnaire weekly, which assessed their internal state. Data analysis and feature engineering were conducted to surface behavioural features that could discern between different levels of stress. These features were used for model development.
Data Collection
- A total of 30,534 DASS-21 surveys were collected from 820 unique participants, providing a comprehensive dataset for analysis.
- Users were recruited through an online platform (Prolific) across the following countries: UK, USA, Ireland, Germany, France, Australia, Canada, Iceland, Israel, Japan, Korea, Netherlands, New Zealand, Singapore, Taiwan.
- Age of recruitment was between 18 and 65.
- Health data included physical activity (steps), sleep patterns, phone unlocks, and more, collected over a period of 6 months.
Model Development
- Logistic regression was employed for classification between healthy and stressed individuals.
- 5-fold cross-validation was used, with each user either only in the training set or only in the test set, to ensure a good measure of generalisability and performance.
- To deal with heavy class imbalance, SMOTE (Synthetic Minority Over-sampling Technique) was used to oversample the training set in each fold.
Results
Data Analysis
In-depth analysis of the collected dataset reveals significant insights into the behavioural patterns associated with varying levels of stress.
Average step count by hour across stress levels
Participants with normal stress levels show a higher and more consistent step count, peaking in the late afternoon. Mild to moderate stress levels follow a similar pattern but at lower counts. Severe and extreme stress levels are associated with lower step counts and greater variability, with an unusual spike for extreme stress late in the day. This suggests that higher stress may be linked to reduced physical activity throughout the day.

Average daily steps by stress level
Individuals with normal stress levels have the highest daily step count, significantly more than those with mild or moderate stress. Severe and extreme categories show a noticeable decrease in daily steps. The trend suggests a negative correlation between stress level and physical activity, with higher stress associated with fewer steps.

Average deviation in steps by stress level
Individuals with normal stress levels generally maintain a consistent step count throughout the day with minimal deviation. Mild to moderate stress shows slightly more variation, while severe and extreme stress levels show the greatest inconsistency. This suggests that higher stress levels might be linked to irregular physical activity patterns.

Average active hours per day by stress level
Individuals with normal stress levels tend to have more active hours in a day, averaging close to 6 hours. Active hours decrease from mild to moderate stress. The severe category reports a slight increase compared to moderate, while extreme stress levels result in fewer active hours, indicating a possible non-linear relationship.

Sudden changes in steps between hours by stress level
Normal stress shows relatively small average differences in step counts, indicating consistent activity. As stress levels increase, there is a trend of larger variations in step counts, suggesting more erratic activity patterns. Extreme stress displays the widest range of change.

Sleep patterns by stress level and chronotype
For Early Bird chronotypes, no-stress participants wake earlier and show more consistent sleep. As stress increases, wake times shift later. For Night Owls, higher stress is associated with more variability in sleep timing, particularly for severe and extreme stress. Both graphs suggest that higher stress correlates with disrupted and inconsistent sleep patterns.

Classification Results
Receiver Operating Characteristic (ROC) Curve
The model achieved an Area Under the Curve (AUC) of 0.76, reflecting good predictive performance. This indicates a 76% chance of correctly distinguishing between positive and negative classes for a randomly selected pair of instances.

Precision-Recall (PR) Curve
The model achieved an Average Precision (AP) score of 0.78, suggesting high precision across varying recall levels and strong performance in identifying the positive class.

Normalised Confusion Matrix
The model correctly predicted true negatives 66% of the time and true positives 71% of the time. Misclassification rates were 34% false positives and 29% false negatives, indicating a balanced performance with a slight preference toward correctly identifying positives.

Discussion
This research aimed to develop a statistical model capable of assessing stress levels based on behavioural health data collected from smartphone sensors, leveraging the ubiquity of smartphones without requiring wearables. The findings offer insights into the relationship between stress and behavioural patterns, particularly physical activity and sleep.
Relationship Between Stress and Physical Activity
The analysis demonstrated a clear correlation between stress levels and physical activity. Participants with normal stress levels exhibited higher and more consistent step counts, suggesting a possible protective effect of physical activity against stress or reduced activity under stress. The trend of reduced step counts and increased variability at higher stress levels supports this hypothesis. This aligns with existing literature indicating that stress can negatively impact physical activity (Smyth et al., 2016), while reduced physical activity can also lower the ability to handle stressful events (Nguyen-Michel et al., 2006).
Stress and Sleep Patterns
Stress levels significantly influenced sleep, with higher stress associated with later sleep and wake times and more variability in sleep patterns. The distinct patterns across stress levels highlight the need for targeted interventions to address sleep disturbances in highly stressed individuals.
Model Performance and Implications
The model performance (AUC 0.76, AP 0.78) indicates promising predictive capability for distinguishing healthy and stressed individuals. The balanced confusion matrix suggests potential for applications in remote monitoring and early intervention in stress-related conditions.
Limitations
- Sample diversity: The sample was limited to smartphone users who opted to participate, which might not fully represent the general population.
- Self-reported measures: The DASS-21 is self-reported, which can introduce biases or inaccuracies.
- Short-term data collection: Data was collected over six months, which may not capture long-term trends or seasonal variations.
- Single modality of stress assessment: The study relied solely on logistic regression; incorporating additional machine learning techniques could provide a more robust analysis.
Future Research Directions
- Expand sample size and diversity to enhance generalisability.
- Conduct longer-term longitudinal studies to observe seasonal and life-event effects.
- Integrate multimodal data analysis, including wearable biometrics, for more comprehensive stress assessment.
- Explore intervention strategies and monitor their effectiveness in real time.
Exploratory Data Analysis and Feature Engineering
The study faced constraints in terms of time and resources, which limited the extent of exploratory data analysis and feature engineering. A more thorough exploration of the collected data and a more sophisticated approach to feature engineering could uncover deeper insights and strengthen the model’s predictive capabilities. The next step would include using raw data from smartphone sensors like accelerometers and gyroscopes to expand feature availability. Processing and extracting meaningful patterns from high-volume, raw sensor data would require advanced techniques such as neural network models and significant computational resources.
Integration of Wearable Data and Vital Sign Monitoring
While this study did not use wearable data in the analysis, incorporating it presents a significant opportunity for model improvement. Wearables like Apple Watches provide detailed data on heart rate and heart rate variability (HRV), which are critical indicators of heart health and the nervous system’s response to stress. HRV, in particular, offers insights into transient stress and the body’s physiological responses. Monitoring these vital signs can enhance the accuracy of stress assessments and provide a means to gauge intervention effectiveness.
Expanding Dataset in a Production Environment
The dataset skew toward healthy and mild-to-moderate stress categories limits the model’s ability to accurately predict higher stress levels. Deploying the model in a production environment, where it is used by real-world users, offers a pathway to address this limitation. In a production setting, the model would have access to a broader and more representative population, enabling continuous feedback and iterative improvements.
Conclusion
This study demonstrates the feasibility of using smartphone sensor data to assess stress levels in the general population. The findings provide insights into the relationship between stress and daily behavioural patterns, offering potential pathways for self-management in stress-related health issues and giving more agency to the user. The use of widely accessible technology like smartphones for health monitoring marks a significant step toward more personalised and preventive healthcare strategies.
References
- Smyth, J., Sliwinski, M., Zawadzki, M., Scott, S., Conroy, D., Lanza, S., Marcusson-Clavertz, D., Kim, J., Stawski, R., Stoney, C., Buxton, O., Sciamanna, C., Green, P., & Almeida, D. (2016). Everyday stress response targets in the science of behavior change. Behaviour Research and Therapy, 101, 20–29. https://doi.org/10.1016/j.brat.2017.09.009
- Nguyen-Michel, S., Unger, J., Hamilton, J., & Spruijt-Metz, D. (2006). Associations between physical activity and perceived stress/hassles in college students. Stress and Health, 22, 179–188. https://doi.org/10.1002/SMI.1094