watchlib is a python library for analyzing and visualizing Apple Watch health data.
DataLoader
CacheHandler
ECGAnimation
WorkoutAnimation
ecg_analysis
ECG
WorkoutRoute
To use this Python package you first have to export the health data:
- Open Health app
- Open your profile in the upper right corner
- Scroll down
- Tap on "Export all health data"
- Confirm that you want to export all health data
- Wait until the export has finished (this might take some minutes)
- Select "Save in files"
- Choose a folder and tap "Save"
- Last step is to unzip the "Export.zip" file
Calculate various heart rate metrics from a 30 second ECG:
- beats per minute (bpm)
- time between heartbeats in ms
- heart rate variability (hrv)
- coming soon: ECG wave detection
- plot ECG
- plot ECG together with metrics
- animate ECG
Filtering workout routes by:
- country
- bounding box size in km
- length of workout in min
3D animation of workout routes:
- coloring based on:
- elevation
- speed
- course
- horizontal acceleration
- vertical acceleration
- loading and converting other health data
coming soon
Watch an example workout animation here