MIT-LCP / mimic-code

MIMIC Code Repository: Code shared by the research community for the MIMIC family of databases
https://mimic.mit.edu
MIT License
2.43k stars 1.5k forks source link

Is the code that performs date shifting available? #1572

Closed sloboy closed 1 year ago

sloboy commented 1 year ago

Prerequisites

Description

I am trying to deidentify healthcare data similar to how MIMIC prepared its data. Is the algorithm that randomly shifts dates and deidentifies DOB of those aged 89 or greater available?

alistairewj commented 1 year ago

No it's not available, but it's not complicated. It's a random offset from a fixed point of time in the patient's stay.

We no longer deidentify DOB per se (it was confusing for a lot of past users). Instead, we provide the age at their first hospital admission (roughly) and if an age is > 89, we set it to 90.

sloboy commented 1 year ago

TY for the quick response. I was looking to borrow a shortcut, but I will implement my own. You are right it is not complicated.

alistairewj commented 1 year ago

Just be sure to use a cryptographically secure shift, and don't roll your own! Good luck!