ncats / CTSA-Metrics

17 stars 16 forks source link

Hard-coded 'UNIQUE_TOTAL_PATIENTS' value in Informatics Metric PCORnet MSSQL #5

Closed bfurner closed 6 years ago

bfurner commented 6 years ago

Line 45 of the following file contains two hard-coded values for UNIQUE_TOTAL_PATIENTS (10):

https://github.com/ncats/CTSA-Metrics/blob/master/Informatics%20Metric%20PCORnet%20MSSQL

Select 'Diagnosis as ICD/SNOMED' as domain, num.cnt as Patients_with_Standards, 10 as UNIQUE_TOTAL_PATIENTS, 100.0 * num.cnt/10 as Percent_Standards, 'Not Applicable' as Values_Present

should be changed to

Select 'Diagnosis as ICD/SNOMED' as domain, num.cnt as Patients_with_Standards, den.cnt as UNIQUE_TOTAL_PATIENTS, 100.0 * num.cnt/den.cnt as Percent_Standards, 'Not Applicable' as Values_Present

KenGersing commented 6 years ago

Script was updated thank you for the test and the clear directions on the error