Closed stephanieshong closed 11 months ago
lt_visit_detail rollup to lt_visit_occurrence - Long term care claims come in monthly chunks even though the visit is continuous with one day difference. For example, as the calendar date moves from Feb 28 to March 1 to April, we have two or three claims instead of one. Therefore, these monthly claims should be merged to into one visit instead of having multiple visits from the claim dates found in the claim records for the same patient. They are continuous visit with one day difference for the same patient.
FYI, starting as my primary effort today. Branch is here.
re-started this week after some leave. Analysis workbook here.
Looks like the ancestor/descendant relationships in OMOP for in-patient and out-patient concepts (9201, 9202) to the medicare concept for hospital code A0 (38004515) are upside down. This makes code in cross-walk creation create a 1-to-many mapping that results in multiple rows. Ticket 120 here.
PR ready with a first() to pick one of the two alues.PR
Within just LT data, without a fix, you get 214k rows in visit_occurrence. With a fix you get 118k. This is confirmed when you see that there are either 95k or 2x 95k rows from A0. To set the context, within all of medicaid (no filter) the visit_occurrence table has 35m rows.
merged Nov. 10 @stephanieshong I don't have permission to close.
@chrisroederucdenver -Thank you. Completed the merge and build over the weekend, 11/11/23! Closing.
LT - long term care claims are submitted in monthly, if the claim contains only one day difference in claim dates merge the visit dates into one such that we do not have multiple visit dates for one stay in a long term care for a patient that last more than a month.