Git Product home page Git Product logo

apple-health-integration's Introduction

Overview

This repository is used for extracting health data from apple health via HealthKit and analyzed in Python. The goal will be to develop an integration of Apple Health data into FHIR to enable better integration with other health applications.

Apple Health integration via HealthKit

I developed a lightweight iOS app using Swift called HealthDataCollector to extract health data from my Apple iPhone via HealthKit. Currently, it's only limited to certain data types and may not contain all the raw data as I'm still learning the schemas for how apple stores their device data, which isn't always from Apple products. All the code can be found in HealthDataCollector and the project files can be found in HealthDataCollector.xcodeproj.

Data processing using Python

Apple's data is exported as JSON and I plan on using Python to do perform ETL on the raw JSON file that will include 1) extraction into pydantic models, 2) enrichment with external data sources, including healthcare data standards, 3) transformation into fast healthcare interoperability resources (FHIR) to enable more seamless transfer to other applications, and 4) import into a Google FHIR Store via the Healthcare API to integrate with a larger, integrated health record.

Snippet of health data extracted from Apple

There's a lot of data that apple aggregates and I'm planning to slowly integrate each one as I find interest in them. Below represents the data types that I've currently extracted along with some other interesting insights during data profiling in Python.

Summary stats

Data type Count Min Max Average Median Period
Step count 544 1.0 1007.0 207.8 72.0 May 26, 2024 - Jun 2, 2024
Active energy burned 5032 0.0 86.4 0.86 0.15 May 26, 2024 - Jun 2, 2024
Heart rate 4551 45 138 90.8 97 May 26, 2024 - Jun 2, 2024

Devices

Name Manufacturer Model Hardware Version Firmware Version Software Version
Apple Watch Apple Inc. Watch Watch6.1 Unknown 10.5
iPhone Apple Inc. iPhone iPhone16.1 Unknown 17.5.1
iPhone Apple Inc. iPhone iPhone16.1 Unknown 17.4.1
Apple Watch via Apple Health Withings Withings Tracker Unknown Unknown Unknown
Body Smart Withings Withings Scale 0 1071 Unknown

apple-health-integration's People

Contributors

ufbfung avatar

Stargazers

 avatar  avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.