%diag_test: a generic SAS macro for evaluating diagnostic accuracy measures for multiple diagnostic tests

Abstract Background Measures of diagnostic test accuracy provide evidence of how well a test correctly identifies or rules-out disease. Commonly used diagnostic accuracy measures (DAMs) include sensitivity and specificity, predictive values, likelihood ratios, area under the receiver operator charac...

Full description

Saved in:
Bibliographic Details
Main Authors: Jacques K. Muthusi, Peter W. Young, Frankline O. Mboya, Samuel M. Mwalili
Format: Article
Language:English
Published: BMC 2025-01-01
Series:BMC Medical Informatics and Decision Making
Subjects:
Online Access:https://doi.org/10.1186/s12911-024-02808-5
Tags: Add Tag
No Tags, Be the first to tag this record!
_version_ 1832594678562684928
author Jacques K. Muthusi
Peter W. Young
Frankline O. Mboya
Samuel M. Mwalili
author_facet Jacques K. Muthusi
Peter W. Young
Frankline O. Mboya
Samuel M. Mwalili
author_sort Jacques K. Muthusi
collection DOAJ
description Abstract Background Measures of diagnostic test accuracy provide evidence of how well a test correctly identifies or rules-out disease. Commonly used diagnostic accuracy measures (DAMs) include sensitivity and specificity, predictive values, likelihood ratios, area under the receiver operator characteristic curve (AUROC), area under precision-recall curves (AUPRC), diagnostic effectiveness (accuracy), disease prevalence, and diagnostic odds ratio (DOR) etc. Most available analysis tools perform accuracy testing for a single diagnostic test using summarized data. We developed a SAS macro for evaluating multiple diagnostic tests using individual-level data that creates a 2 × 2 summary table, AUROC and AUPRC as part of output. Methods The SAS macro presented here is automated to reduce analysis time and transcription errors. It is simple to use as the user only needs to specify the input dataset, “standard” and “test” variables and threshold values. It creates a publication-quality output in Microsoft Word and Excel showing more than 15 different accuracy measures together with overlaid AUROC and AUPRC graphics to help the researcher in making decisions to adopt or reject diagnostic tests. Further, it provides for additional variance estimation methods other than the normal distribution approximation. Results We tested the macro for quality control purposes by reproducing results from published work on evaluation of multiple types of dried blood spots (DBS) as an alternative for human immunodeficiency virus (HIV) viral load (VL) monitoring in resource-limited settings compared to plasma, the gold-standard. Plasma viral load reagents are costly, and blood must be prepared in a reference laboratory setting by a qualified technician. On the other hand, DBS are easy to prepare without these restrictions. This study evaluated the suitability of DBS from venous, microcapillary and direct spotting DBS, hence multiple diagnostic tests which were compared to plasma specimen. We also used the macro to reproduce results of published work on evaluating performance of multiple classification machine learning algorithms for predicting coronary artery disease. Conclusion The SAS macro presented here is a powerful analytic tool for analyzing data from multiple diagnostic tests. The SAS programmer can modify the source code to include other diagnostic measures and variance estimation methods. By automating analysis, the macro adds value by saving analysis time, reducing transcription errors, and producing publication-quality outputs.
format Article
id doaj-art-3055994e08b94b8daedae98cdc6987d7
institution Kabale University
issn 1472-6947
language English
publishDate 2025-01-01
publisher BMC
record_format Article
series BMC Medical Informatics and Decision Making
spelling doaj-art-3055994e08b94b8daedae98cdc6987d72025-01-19T12:26:01ZengBMCBMC Medical Informatics and Decision Making1472-69472025-01-0125111610.1186/s12911-024-02808-5%diag_test: a generic SAS macro for evaluating diagnostic accuracy measures for multiple diagnostic testsJacques K. Muthusi0Peter W. Young1Frankline O. Mboya2Samuel M. Mwalili3Division of Global HIV and Tuberculosis, Global Health Centre, U.S. Centres for Disease Control and PreventionDivision of Global HIV and Tuberculosis, Global Health Centre, U.S. Centres for Disease Control and PreventionDivision of Global HIV and Tuberculosis, Global Health Centre, U.S. Centres for Disease Control and PreventionInstitute of Mathematical Sciences Centre for Health Analytics and Modelling (CHaM), Strathmore UniversityAbstract Background Measures of diagnostic test accuracy provide evidence of how well a test correctly identifies or rules-out disease. Commonly used diagnostic accuracy measures (DAMs) include sensitivity and specificity, predictive values, likelihood ratios, area under the receiver operator characteristic curve (AUROC), area under precision-recall curves (AUPRC), diagnostic effectiveness (accuracy), disease prevalence, and diagnostic odds ratio (DOR) etc. Most available analysis tools perform accuracy testing for a single diagnostic test using summarized data. We developed a SAS macro for evaluating multiple diagnostic tests using individual-level data that creates a 2 × 2 summary table, AUROC and AUPRC as part of output. Methods The SAS macro presented here is automated to reduce analysis time and transcription errors. It is simple to use as the user only needs to specify the input dataset, “standard” and “test” variables and threshold values. It creates a publication-quality output in Microsoft Word and Excel showing more than 15 different accuracy measures together with overlaid AUROC and AUPRC graphics to help the researcher in making decisions to adopt or reject diagnostic tests. Further, it provides for additional variance estimation methods other than the normal distribution approximation. Results We tested the macro for quality control purposes by reproducing results from published work on evaluation of multiple types of dried blood spots (DBS) as an alternative for human immunodeficiency virus (HIV) viral load (VL) monitoring in resource-limited settings compared to plasma, the gold-standard. Plasma viral load reagents are costly, and blood must be prepared in a reference laboratory setting by a qualified technician. On the other hand, DBS are easy to prepare without these restrictions. This study evaluated the suitability of DBS from venous, microcapillary and direct spotting DBS, hence multiple diagnostic tests which were compared to plasma specimen. We also used the macro to reproduce results of published work on evaluating performance of multiple classification machine learning algorithms for predicting coronary artery disease. Conclusion The SAS macro presented here is a powerful analytic tool for analyzing data from multiple diagnostic tests. The SAS programmer can modify the source code to include other diagnostic measures and variance estimation methods. By automating analysis, the macro adds value by saving analysis time, reducing transcription errors, and producing publication-quality outputs.https://doi.org/10.1186/s12911-024-02808-5SAS macroDisease prevalenceDiagnostic accuracy measuresReproducible researchMachine learning classification
spellingShingle Jacques K. Muthusi
Peter W. Young
Frankline O. Mboya
Samuel M. Mwalili
%diag_test: a generic SAS macro for evaluating diagnostic accuracy measures for multiple diagnostic tests
BMC Medical Informatics and Decision Making
SAS macro
Disease prevalence
Diagnostic accuracy measures
Reproducible research
Machine learning classification
title %diag_test: a generic SAS macro for evaluating diagnostic accuracy measures for multiple diagnostic tests
title_full %diag_test: a generic SAS macro for evaluating diagnostic accuracy measures for multiple diagnostic tests
title_fullStr %diag_test: a generic SAS macro for evaluating diagnostic accuracy measures for multiple diagnostic tests
title_full_unstemmed %diag_test: a generic SAS macro for evaluating diagnostic accuracy measures for multiple diagnostic tests
title_short %diag_test: a generic SAS macro for evaluating diagnostic accuracy measures for multiple diagnostic tests
title_sort diag test a generic sas macro for evaluating diagnostic accuracy measures for multiple diagnostic tests
topic SAS macro
Disease prevalence
Diagnostic accuracy measures
Reproducible research
Machine learning classification
url https://doi.org/10.1186/s12911-024-02808-5
work_keys_str_mv AT jacqueskmuthusi diagtestagenericsasmacroforevaluatingdiagnosticaccuracymeasuresformultiplediagnostictests
AT peterwyoung diagtestagenericsasmacroforevaluatingdiagnosticaccuracymeasuresformultiplediagnostictests
AT franklineomboya diagtestagenericsasmacroforevaluatingdiagnosticaccuracymeasuresformultiplediagnostictests
AT samuelmmwalili diagtestagenericsasmacroforevaluatingdiagnosticaccuracymeasuresformultiplediagnostictests