healmatcher
healmatcheris a simple but fast probabilistic data matching package developed by NYULH HEAL Lab.- The package is best optimized for matching healthcare database (e.g. EHR) as it has designed to link Medicaid and Client Database System data.
Splink packageis extensively being used to run core linkage processes.- Currently, the model supports 4 variables (
sex,date of birth,last 4 digits of ssn, andfirst 2 letters of last name) to run the linkage process.
How to install
pip install healmatcher
How to use (example)
# Install package
!pip install healmatcher
# Load package
from healmatcher import hm
# create example dataset
testa = pd.DataFrame({
'sex':[1,2,1,2,1,2,1,2,1,2],
'dob':['2012-1-1','2011-12-1','1999-1-1','1998-11-1','2012-11-1','1984-1-1','1982-1-1','1975-1-1','1967-1-1','1954-1-1'],
'ssn':[1111,2222,3333,4444,5555,6666,7777,8888,9999,1010],
'ln':["as",'ss','zz','rr','ww','wa','tr','tt','hh','gq'],
'PROVIDER_NUMBER':[2,1,1,1,1,1,1,1,2,1]
})
testb = pd.DataFrame({
'sex':[2,2,1,1,1,2,1,2,1,1],
'dob':['2012-1-1','2001-12-1','1999-1-1','1998-11-1','2012-11-1','1984-1-1','1982-1-1','1975-1-1','1967-1-1','1954-1-1'],
'ssn':[1111,2222,3333,4444,5555,6666,7777,8888,9999,1010],
'ln':["as",'ls','zz','rr','wb','wa','tr','tt','ha','gq'],
'PROVIDER_NUMBER':[2,1,1,1,1,1,1,1,2,1]
# Run matching
hm(
df_a = testa,
df_b = testb,
col_a=['sex','dob','ssn','ln'],
col_b=['sex','dob','ssn','ln'],
match_prob_threshold = 0.001,
iteration = 20,
model2 = True,
blocking_rule_for_training_input = 'PROVIDER_NUMBER',
onetoone = True,
match_summary = True
)
Updates
use_save_model=True: Load pre-trained model to run matchingsave_model_path = PATH: add path to load a model (json format)export_model=True: argument to save current modelexport_model_path=PATH: add path to save current model
Follow up
- Please visit our repo if you have any questions.
Webpage
Metadata
Release files for healmatcher 0.0.49
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| healmatcher-0.0.49.tar.gz | 7.3 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| healmatcher-0.0.49-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 14.8 kB
Release files / healmatcher-0.0.49.tar.gz
| Download URL | healmatcher-0.0.49.tar.gz |
|---|---|
| Size | 7.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
626e156ffe6a9d0a3945d898f8cbd6d1a1f22b718c5ed9628e74d32279c5b062
|
|
BLAKE2b-256 checksum How to use checksums |
98ccda1908a649ee70b0ff1069680a38ecd0e1b04e695da0b2bb896a1715d4d7
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.0.0 CPython/3.8.0
|
Release files / healmatcher-0.0.49-py3-none-any.whl
| Download URL | healmatcher-0.0.49-py3-none-any.whl |
|---|---|
| Size | 7.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
121d84f32262be9d7913b4ea60f1c4c6d5df446137e1f1f0be3c6a1f3bebaec0
|
|
BLAKE2b-256 checksum How to use checksums |
e6cd706d6761bd25776908969edd919c52dc31ea7dd3f722b6e0f8f4acdace7e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.0.0 CPython/3.8.0
|