Open stephenrho opened 2 years ago
Ok I looked some more and it looks like all ICD 9 procedure codes in src/pccc.cpp are not padded in accordance with the documentation
ICD 9 codes: Codes less than 10 should be left padded with 2 zeros. Codes less than 100 should be left padded with 1 zero.
Is this deliberate? I can't see anywhere that says the padding is specific to diagnosis codes. Also for codes < 1 I would assume they should be padded by "000": e.g.,
> icd::decimal_to_short("00.93")
[1] "00093"
Thanks! I'll review this and our test suite and let you know if I see any issues.
I seem to recall a reason for not padding - could have just been how the original SAS code did it. Will have to think about it a bit.
I think I've noticed some errors in the ICD9 procedure codes for the metabolic CCC.
Shouldn't '064' and '073' be '0064' and '0073', respectively? Otherwise I match 64.0/0640 = circumcision or 73.0 = procedures during delivery.
Thanks