SlideShare a Scribd company logo
A Quest For Better Sleep
(with Fitbit data analysis)
Alex Martinelli | @5agado
Index
● Why?
● The Data
● Exploring Sleep Data
● The Heatmap Case
● Correlation
● What’s Next?
2/15
Why?
Be your own data scientist!
Learn..
How data “works”: play with it, learn about tools, statistics and biases.
Learn to give a meaning to data < learn to give a proper meaning to data.
..and Learn
How you “work”: an app dashboard is not enough.
Investigation based on your needs and knowledge: insight, diagnosis, experiments
and improvements.
3/15
The Data
Premise: sleep trackers and their inherent inaccuracy
The Fitbit case
Getting your data is not as easy as expected, considering that is YOUR data.
Options: premium plan, scraping or APIs (again with limitations)
Data format (cleaned)
For each minute: 0=None (no measure taken), 1=Sleeping, 2=Restless, 3=Awake
Sleeping periods can be manually recorded, or are otherwise recognized
automatically (based on amount of time you didn’t move, so there are limitations).
4/15
Data image (table)
Exploring Sleep Data
Basic Stats
- sleep efficiency, hours of sleep...
Timing Stats
- to bed time, wake up time
- sleep intervals
Intraday Stats (minute to minute analysis)
Aggregation (hour, weekday, month, year)
Correlation
6/15
7/15
8/15
“Looks cool, but what does it mean?”
[cit. everyone]
9/15
Minute Sleep Quality
For each minute, what percentage of recorded “times in bed” I was actually asleep
10/15
Correlation
Premise: just observations. We need more formal experiments to show causal
connections.
● No correlation between steps and sleep quality (see next slide image)
● Daily heart resting rate negatively correlates with sleep efficiency
● Alcohol: asleep instantly, less restless, but more awakenings
● Supplements
Melatonin: decrease in sleep efficiency, while minor increase with 5HTP
Not enough data for vitamin B complex
11/15
12/15
What’s Next?
● More data for correlation (drinking, eating, activity, cognitive performances,
habits and routines)
● Self experimentation to support causal relationship hypotheses
● Demographics
● Predictive models?
● Real quality data: EEG integration
● A personal quirky case: lucid dreaming
13/15
Q&A
Useful Links
1. Introductory article for this project
(https://medium.com/@5agado/a-quest-for-better-sleep-with-fitbit-data-analysis-5f10b3f548a#.925f35k2f)
2. Github repository with project code (https://github.com/5agado/fitbit-analyzer)
3. Intraday data via personal apps - Fitbit announcement post
(https://community.fitbit.com/t5/Web-API/Intraday-data-now-immediately-available-to-personal-apps/td-p/1014524)
4. Study on Fitbit accuracy on sleep measurements (https://www.ncbi.nlm.nih.gov/pubmed/21971963)
5. Cross-sectional study on the validity of consumer-level wearables
(https://ijbnpa.biomedcentral.com/articles/10.1186/s12966-015-0201-9)
15/15

More Related Content

PDF
Ml masterclass
PPTX
Spreadsheet Errors
PDF
Noam Finkelstein - The Importance of Modeling Data Collection
PPTX
Guide to data analytics
PDF
Phone addiction
PDF
Bridging the Gap: Machine Learning for Ubiquitous Computing -- Study Design a...
PDF
MLSEV Virtual. Supervised vs Unsupervised
PDF
MLSEV Virtual. Evaluations
Ml masterclass
Spreadsheet Errors
Noam Finkelstein - The Importance of Modeling Data Collection
Guide to data analytics
Phone addiction
Bridging the Gap: Machine Learning for Ubiquitous Computing -- Study Design a...
MLSEV Virtual. Supervised vs Unsupervised
MLSEV Virtual. Evaluations

What's hot (15)

PDF
Influx/Days 2017 San Francisco | Baron Schwartz
PPTX
Big data chicago v2 5 14 14
PPTX
Understanding randomness
PPTX
Introduction to machine learning
PDF
MLSEV Virtual. Predictions
PDF
MLSEV Virtual. Automating Model Selection
PDF
Data Journalism 2: Interrogating, Visualising and Mashing
PDF
Hustling 101: Business Metrics for Your Website
PPTX
Splunk live! Customer Presentation – Prelert
PPTX
Distributions: Normal with Matt Hansen at StatStuff
PPTX
SplunkLive! Prelert Session - Extending Splunk with Machine Learning
PDF
Data Science Methodology for Analytics and Solution Implementation
PDF
MLSEV Virtual. State of the Art in ML
PPTX
Freeblade - A retrospective
PPT
HadoopSummit2015_SelfEvolvingModels
Influx/Days 2017 San Francisco | Baron Schwartz
Big data chicago v2 5 14 14
Understanding randomness
Introduction to machine learning
MLSEV Virtual. Predictions
MLSEV Virtual. Automating Model Selection
Data Journalism 2: Interrogating, Visualising and Mashing
Hustling 101: Business Metrics for Your Website
Splunk live! Customer Presentation – Prelert
Distributions: Normal with Matt Hansen at StatStuff
SplunkLive! Prelert Session - Extending Splunk with Machine Learning
Data Science Methodology for Analytics and Solution Implementation
MLSEV Virtual. State of the Art in ML
Freeblade - A retrospective
HadoopSummit2015_SelfEvolvingModels
Ad

Viewers also liked (20)

PPTX
Future Trends in Wearables & Big Data
PPTX
Van CV naar Click-2-Apply
PPTX
Presentation2
ODP
Great presentations
PPTX
Overview of Business Administration
DOC
PPTX
Evaluation 2
PDF
6 ways to shake up social your app
 
PDF
Audit of Gulen operated Magnolia Science Academy
PDF
Scottish Liberal Democrat Conference 2011: Ipsos MORI briefing pack
DOC
XV рейтинг политической выживаемости губернаторов
PDF
DistribEx - сервис для автоматизации обмена информацией между производителям...
PDF
აკა მორჩილაძეს 14 ნაწარმოები
PDF
Electric Utility Solutions: Voltage Regulation
PDF
Zubin Master MedicReS World Congress 2014
PDF
LE SECTEUR DU RECRUTEMENT, « VERS UNE INFORMATION PARFAITE »
PPTX
Introduction to deep learning
PDF
Registro en el Campus Chamilo y Matriculación en un Curso
PPTX
Planejamento estratégico - CAPEDE
PPTX
Cloud days | IoTプラットフォームSORACOM
Future Trends in Wearables & Big Data
Van CV naar Click-2-Apply
Presentation2
Great presentations
Overview of Business Administration
Evaluation 2
6 ways to shake up social your app
 
Audit of Gulen operated Magnolia Science Academy
Scottish Liberal Democrat Conference 2011: Ipsos MORI briefing pack
XV рейтинг политической выживаемости губернаторов
DistribEx - сервис для автоматизации обмена информацией между производителям...
აკა მორჩილაძეს 14 ნაწარმოები
Electric Utility Solutions: Voltage Regulation
Zubin Master MedicReS World Congress 2014
LE SECTEUR DU RECRUTEMENT, « VERS UNE INFORMATION PARFAITE »
Introduction to deep learning
Registro en el Campus Chamilo y Matriculación en un Curso
Planejamento estratégico - CAPEDE
Cloud days | IoTプラットフォームSORACOM
Ad

Similar to Data Mining Sleep Data (20)

PDF
Introduction to data sciceeeeeeeeeeeeeeeeeeee
PDF
Wearable Horizons: The quantified lifestyle
PDF
IRJET- An Empirical Study on Effect of Sleep Deprivation
PDF
Computer games for user engagement in Attention Deficit Hyperactivity Disorde...
PDF
SIGIR15-NeuroIR
PDF
The Hidden Stories Behind Missing Data
PDF
AI and Mental Health (MAS.S60): Final Project
PDF
Statistics in Journalism
PPTX
E bay amplify_final
PPTX
Top 5 tips on how to learn statistics more effectively
PDF
Beyond steps
PPTX
CIA Intelligence Analysis for Testers
PDF
https://www.academia.edu/81610651/FURTHER_INVESTIGATIONS_ON_DEVELOPING_AN_ARA...
PDF
DTWDIR: AN ENHANCED DTW ALGORITHM FOR AUTISTIC CHILD BEHAVIOUR MONITORING
PPTX
Mental Wellness Analyzer: Leveraging Data for Better Mental Health Insights -...
PDF
Using fairness metrics to solve ethical dilemmas of machine learning
PDF
DETECTING PSYCHOLOGICAL INSTABILITY USING MACHINE LEARNING
PDF
Programming Emotions
PPTX
Early stage of diabetics prediction using machine learnin
PDF
IJSRED-V2I5P44
Introduction to data sciceeeeeeeeeeeeeeeeeeee
Wearable Horizons: The quantified lifestyle
IRJET- An Empirical Study on Effect of Sleep Deprivation
Computer games for user engagement in Attention Deficit Hyperactivity Disorde...
SIGIR15-NeuroIR
The Hidden Stories Behind Missing Data
AI and Mental Health (MAS.S60): Final Project
Statistics in Journalism
E bay amplify_final
Top 5 tips on how to learn statistics more effectively
Beyond steps
CIA Intelligence Analysis for Testers
https://www.academia.edu/81610651/FURTHER_INVESTIGATIONS_ON_DEVELOPING_AN_ARA...
DTWDIR: AN ENHANCED DTW ALGORITHM FOR AUTISTIC CHILD BEHAVIOUR MONITORING
Mental Wellness Analyzer: Leveraging Data for Better Mental Health Insights -...
Using fairness metrics to solve ethical dilemmas of machine learning
DETECTING PSYCHOLOGICAL INSTABILITY USING MACHINE LEARNING
Programming Emotions
Early stage of diabetics prediction using machine learnin
IJSRED-V2I5P44

More from Quantified Self Dublin (19)

PPTX
Quantified Wellness and Assisted Living
PDF
Quantified Brain Health
PPTX
Nutrigenomics, Biomarkers & Health
PPT
Gut hormones - Appetite, Mood and Health
PPTX
Self Quantifying Health
PPTX
Biohacking Sleep
PPTX
Quantified Sleep - Science behind the sleep trackers
PPTX
IoT Data as Service with Hadoop
PPTX
Quantifying and Treating Stress
PPTX
Evolution of Wearables - Past, Present, Future
PPTX
The Future of Quantified Self in Healthcare
PPTX
Quantified Self & Personal Healthcare
PDF
Kenkodo Quantified Self Dublin June 2016
PPTX
Food and Activity Detection in Life Logging Images
PDF
Food and Activity Detection in Life Logging Images
PPTX
Improving Mental Focus
PPTX
Introduction to HRV
PDF
Introduction to Google Fit
PDF
How Lightbulbs Made Alarm Clocks
Quantified Wellness and Assisted Living
Quantified Brain Health
Nutrigenomics, Biomarkers & Health
Gut hormones - Appetite, Mood and Health
Self Quantifying Health
Biohacking Sleep
Quantified Sleep - Science behind the sleep trackers
IoT Data as Service with Hadoop
Quantifying and Treating Stress
Evolution of Wearables - Past, Present, Future
The Future of Quantified Self in Healthcare
Quantified Self & Personal Healthcare
Kenkodo Quantified Self Dublin June 2016
Food and Activity Detection in Life Logging Images
Food and Activity Detection in Life Logging Images
Improving Mental Focus
Introduction to HRV
Introduction to Google Fit
How Lightbulbs Made Alarm Clocks

Recently uploaded (20)

PPT
genitourinary-cancers_1.ppt Nursing care of clients with GU cancer
PDF
Handout_ NURS 220 Topic 10-Abnormal Pregnancy.pdf
PPTX
Respiratory drugs, drugs acting on the respi system
PPTX
anaemia in PGJKKKKKKKKKKKKKKKKHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHH...
PPTX
CHEM421 - Biochemistry (Chapter 1 - Introduction)
PPTX
Human Reproduction: Anatomy, Physiology & Clinical Insights.pptx
PPTX
Neuropathic pain.ppt treatment managment
PPTX
Stimulation Protocols for IUI | Dr. Laxmi Shrikhande
PDF
Medical Evidence in the Criminal Justice Delivery System in.pdf
PPT
STD NOTES INTRODUCTION TO COMMUNITY HEALT STRATEGY.ppt
PPTX
anal canal anatomy with illustrations...
DOC
Adobe Premiere Pro CC Crack With Serial Key Full Free Download 2025
PPT
Copy-Histopathology Practical by CMDA ESUTH CHAPTER(0) - Copy.ppt
PPTX
neonatal infection(7392992y282939y5.pptx
PPTX
ca esophagus molecula biology detailaed molecular biology of tumors of esophagus
PPTX
surgery guide for USMLE step 2-part 1.pptx
PDF
شيت_عطا_0000000000000000000000000000.pdf
PPTX
Important Obstetric Emergency that must be recognised
PPT
1b - INTRODUCTION TO EPIDEMIOLOGY (comm med).ppt
PPTX
MANAGEMENT SNAKE BITE IN THE TROPICALS.pptx
genitourinary-cancers_1.ppt Nursing care of clients with GU cancer
Handout_ NURS 220 Topic 10-Abnormal Pregnancy.pdf
Respiratory drugs, drugs acting on the respi system
anaemia in PGJKKKKKKKKKKKKKKKKHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHH...
CHEM421 - Biochemistry (Chapter 1 - Introduction)
Human Reproduction: Anatomy, Physiology & Clinical Insights.pptx
Neuropathic pain.ppt treatment managment
Stimulation Protocols for IUI | Dr. Laxmi Shrikhande
Medical Evidence in the Criminal Justice Delivery System in.pdf
STD NOTES INTRODUCTION TO COMMUNITY HEALT STRATEGY.ppt
anal canal anatomy with illustrations...
Adobe Premiere Pro CC Crack With Serial Key Full Free Download 2025
Copy-Histopathology Practical by CMDA ESUTH CHAPTER(0) - Copy.ppt
neonatal infection(7392992y282939y5.pptx
ca esophagus molecula biology detailaed molecular biology of tumors of esophagus
surgery guide for USMLE step 2-part 1.pptx
شيت_عطا_0000000000000000000000000000.pdf
Important Obstetric Emergency that must be recognised
1b - INTRODUCTION TO EPIDEMIOLOGY (comm med).ppt
MANAGEMENT SNAKE BITE IN THE TROPICALS.pptx

Data Mining Sleep Data

  • 1. A Quest For Better Sleep (with Fitbit data analysis) Alex Martinelli | @5agado
  • 2. Index ● Why? ● The Data ● Exploring Sleep Data ● The Heatmap Case ● Correlation ● What’s Next? 2/15
  • 3. Why? Be your own data scientist! Learn.. How data “works”: play with it, learn about tools, statistics and biases. Learn to give a meaning to data < learn to give a proper meaning to data. ..and Learn How you “work”: an app dashboard is not enough. Investigation based on your needs and knowledge: insight, diagnosis, experiments and improvements. 3/15
  • 4. The Data Premise: sleep trackers and their inherent inaccuracy The Fitbit case Getting your data is not as easy as expected, considering that is YOUR data. Options: premium plan, scraping or APIs (again with limitations) Data format (cleaned) For each minute: 0=None (no measure taken), 1=Sleeping, 2=Restless, 3=Awake Sleeping periods can be manually recorded, or are otherwise recognized automatically (based on amount of time you didn’t move, so there are limitations). 4/15
  • 6. Exploring Sleep Data Basic Stats - sleep efficiency, hours of sleep... Timing Stats - to bed time, wake up time - sleep intervals Intraday Stats (minute to minute analysis) Aggregation (hour, weekday, month, year) Correlation 6/15
  • 9. “Looks cool, but what does it mean?” [cit. everyone] 9/15
  • 10. Minute Sleep Quality For each minute, what percentage of recorded “times in bed” I was actually asleep 10/15
  • 11. Correlation Premise: just observations. We need more formal experiments to show causal connections. ● No correlation between steps and sleep quality (see next slide image) ● Daily heart resting rate negatively correlates with sleep efficiency ● Alcohol: asleep instantly, less restless, but more awakenings ● Supplements Melatonin: decrease in sleep efficiency, while minor increase with 5HTP Not enough data for vitamin B complex 11/15
  • 12. 12/15
  • 13. What’s Next? ● More data for correlation (drinking, eating, activity, cognitive performances, habits and routines) ● Self experimentation to support causal relationship hypotheses ● Demographics ● Predictive models? ● Real quality data: EEG integration ● A personal quirky case: lucid dreaming 13/15
  • 14. Q&A
  • 15. Useful Links 1. Introductory article for this project (https://medium.com/@5agado/a-quest-for-better-sleep-with-fitbit-data-analysis-5f10b3f548a#.925f35k2f) 2. Github repository with project code (https://github.com/5agado/fitbit-analyzer) 3. Intraday data via personal apps - Fitbit announcement post (https://community.fitbit.com/t5/Web-API/Intraday-data-now-immediately-available-to-personal-apps/td-p/1014524) 4. Study on Fitbit accuracy on sleep measurements (https://www.ncbi.nlm.nih.gov/pubmed/21971963) 5. Cross-sectional study on the validity of consumer-level wearables (https://ijbnpa.biomedcentral.com/articles/10.1186/s12966-015-0201-9) 15/15