After anxiously awaiting the results of a medical test, patients who test negative experience understandable relief. However, a false negative can lead to a potentially life-threatening condition going untreated. Reducing the occurrence of false negatives—particularly when using artificial intelligence (AI) in diagnostics—is crucial.

Today, AI is deployed more often to predict life-threatening disease. However, there remains a challenge to get the machine learning (ML) algorithms precise enough to correctly diagnose whether a patient is sick. ML is the branch of AI where algorithms learn from datasets and get smarter in the process.

In general, algorithms have been more accurate at saying people do not have a disease than identifying the ones who are sick, says Ibomoiye Domor Mienye, PhD, a postdoctoral AI researcher at the University of Johannesburg (UJ). This is an ongoing challenge in healthcare AI.

The reason is the way the algorithms learn. For healthcare applications, the algorithms learn from datasets that come from large hospitals or state healthcare programs, but most of the people in those datasets do not have the conditions they are being tested for, says Mienye.

“At a large hospital, a person comes in to get tested for chronic kidney disease (CKD),” he says. “Their doctor sent them there because some of their symptoms are CKD symptoms. The doctor would like to rule out CKD. Turns out, the person does not have CKD. This happens with lots of people. The dataset ends up with more people who do not have CKD, than people who do. We call this an imbalanced dataset.”

When an algorithm starts learning from the dataset, it learns far less about CKD than it should and is not accurate enough at diagnosing ill patients—unless the algorithm is adjusted for the imbalance.

“Let’s say there is a dataset about a serious disease,” Mienye says. “The dataset has 90 people who do not have the disease, but 10 of the people do have the disease. As an example, an ML algorithm says that the 90 do not have the disease. That is correct so far. But it fails to diagnose the 10 that do have the disease. The algorithm is still regarded as 90% accurate.”

This is because accuracy has been defined in this way. However, for health outcomes, it may be urgent to diagnose the 10 people with the disease and get them into treatment. That may be more important than complete accuracy about the 90 who do not have the condition, Mienye adds.

Penalties Against AI

In a research study published in Informatics in Medicine Unlocked, Mienye and Yanxia Sun, DTech, PhD, a professor from the department of electrical and engineering science at UJ, show how ML algorithms can be improved significantly for medical purposes. They used logistic regression, decision tree, XGBoost, and random forest algorithms. These are supervised binary classification algorithms, which means they only learn from the “yes/no” datasets provided to them.

The researchers built cost sensitivity into each of the algorithms. This means the algorithm gets a much bigger penalty for telling a sick person in the dataset that they are healthy, than the other way round. In medical terms, the algorithms get bigger penalties for false negatives than for false positives.

Mienye and Sun used public learning datasets for diabetes, breast cancer, cervical cancer (858 records), and chronic kidney disease (400 records). The datasets come from large hospitals or healthcare programs. In these binary datasets, people are classified as either having a disease or not having it at all.

The algorithms they used are binary also. These can say “yes, the person has the disease” or “no, they don’t have it.” They tested all the algorithms on each dataset, both with and without the cost-sensitivity.

The results make it clear that the penalties work as intended in these datasets. For CKD, for example, the random forest algorithm had precision at 0.972 and recall at 0.946, out of a perfect 1.000. After the cost-sensitivity was added, the algorithm improved significantly to precision at 0.990 and recall at a perfect 1.000. For CKD, the three other algorithms’ recall improved from high scores to a perfect 1.000.

Precision at 1.000 means the algorithm did not predict one or more false positives across the entire dataset. Recall at 1.000 means the algorithm did not predict one or more false negatives across the entire dataset.

With the other datasets, the results were different for different algorithms. For cervical cancer, the cost-sensitive random forest and XGBoost algorithms improved from high scores to perfect precision and recall. However, the logistic regression and decision tree algorithms improved to much higher scores but did not reach 1.000.

Future Implications

Mienye grew up in a village near the Atlantic Ocean that is not accessible by road.

“You have to use a speedboat from the nearest town to get there. The boat ride takes two to three hours,” he says.

The nearest clinic is in the bigger town, on the other side of the boat ride. The deep rural setting of his home village inspired him to see how AI can help people with little or no access to healthcare.

Imagining an old woman from his village is a good way to think about how more advanced AI algorithms may assist in future, he says. For example, a cost-sensitive multiclass ML algorithm could assess the measured data for her blood pressure, sodium levels, and blood sugar. If her data is recorded correctly on a computer and the algorithm is learning from a multiclass dataset, that future AI could tell clinic staff which stage of chronic kidney disease she is at.

This village scenario is in the future, however.

Meanwhile the study’s four algorithms with cost sensitivity are far more precise at diagnosing disease in their numerical datasets—and they learn quickly, using the ordinary computer that one could expect to find in a remote town.

Featured Image: Giving a big penalty to an algorithm for false negatives results in much better precision, UJ researchers find. The research appears in Informatics in Medicine Unlocked. Illustration: Graphic design by Therese van Wyk, University of Johannesburg. Based on Pixabay images.