outcomesinsights / conceptql

A high-level language that allows researchers to unambiguously define their research algorithms.
MIT License
17 stars 6 forks source link

Add superficial checks for codes entered into selector operators #45

Closed jenniferduryea closed 8 years ago

jenniferduryea commented 8 years ago

We should still add some checks to the data entered into each operator to make sure users are adding in valid data. These would show up as warnings and will not prevent users from saving an algorithm or running an algorithm. I suggest the following checks be added:

ICD-9 CM - allow characters in the following formats: xxx xxx.x xxx.xx Exxx.x ICD-9 proc - allow characters in the following formats: xx xx.x xx.xx ICD-10 proc - 7 characters ICD-10 CM - xxx, xxx.x, xxx.xx, xxx.xxx, xxx.xxxx CPT/HCPCS, CPT, HCPCS - 5 characters DRG - 3 integers

Note: this was originally an issue posted in the jigsaw-diagram-editor repo (https://github.com/outcomesinsights/jigsaw-diagram-editor/issues/156)

jenniferduryea commented 8 years ago

confirmed the JAM is checking for these formats in each operator listed. Note that ICD-10 proc will always come back with a warning of "unknown concept" because the OHDSI vocabularies do not have any ICD10 procedure codes. But we still check for valid formats. Closing out.