Skip to content

EHR queries - #103

Draft
jeremyestein wants to merge 49 commits into
devfrom
ehr_queries_clean
Draft

EHR queries#103
jeremyestein wants to merge 49 commits into
devfrom
ehr_queries_clean

Conversation

@jeremyestein

Copy link
Copy Markdown
Collaborator

I have linearised the previous branches somewhat and removed all merges from dev (or janitoring), then done a big merge at the end. This takes us up to the equivalent of commit 061dca7 in the other branch.

skeating and others added 30 commits February 2, 2026 15:06
Introduces new queries for airway and sputum/secretions data, and refactors the flow sheet query to consolidate multiple values into a wider format. A new README documents the overall data extraction goal and the current set of scripts.
Transforms specific lab test results (e.g., CRP, WCC) from a long format into distinct columns using `MAX() FILTER`. This enables direct consumption of lab data in a wider format, simplifying downstream analysis.

Additionally, the query is updated to use parameters for `hospital_visit_id` and to include date range filtering, improving its flexibility.
@codecov

codecov Bot commented Sep 10, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 72.93233% with 36 lines in your changes missing coverage. Please review.
✅ Project coverage is 73.05%. Comparing base (c031618) to head (7968f17).

Files with missing lines Patch % Lines
src/db.py 53.84% 30 Missing and 6 partials ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##              dev     #103      +/-   ##
==========================================
+ Coverage   72.71%   73.05%   +0.33%     
==========================================
  Files          15       16       +1     
  Lines         722      835     +113     
  Branches       67       75       +8     
==========================================
+ Hits          525      610      +85     
- Misses        175      197      +22     
- Partials       22       28       +6     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants