Skip to Content

Prediction Analysis

Context

The Prediction Analysis tool allows you to examine the predictive performance of a network model interactively. It generates a new causal network to represent the performance dynamics of the original model. This approach can help you interpret concepts such as precision, reliability, true/false positives, true/false negatives, etc. As a result, the usefulness of the model can be assessed and explained in detail.

Usage and example

Before you can initiate a Prediction Analysis, you need to have a network that was learned using Supervised Learning. Ideally, you would perform all other validation and performance testing steps, e.g., Structural Coefficient Analysis and Cross-Validation, before launching Prediction Analysis.

For demonstration purposes, we show a Prediction Analysis based on a model for diagnosing coronary artery disease. We originally developed this model in a webinar on Diagnostic Decision Support.

CoronaryArteryDisease.xbl
XBL

With this network active in the Graph Window, switch to Validation Mode and select Menus > Tools > Prediction Analysis.

The Tools menu in Validation Mode with Prediction Analysis highlighted

BayesiaLab generates a new model and opens a new Graph Window for it.

Loading SVG...

By default, BayesiaLab attaches the suffix “_prediction” to the original file name.

Now, switch to the Validation Mode and bring up all nodes as Monitors in the Monitor Panel.

Prediction Analysis in Validation Mode with the network on the left and all six Monitors on the right

The node Actual State\mathit{Actual\ State} represents the ground truth for the Target Node, i.e., the node Condition\mathit{Condition} in the network, which we are analyzing here.

The nodes P(Coronary Artery Disease)\mathit{P(Coronary\ Artery\ Disease)} and P(Normal)\mathit{P(Normal)} show the distributions of the probabilities predicted by the network for each state.

The node Predicted State Probability\mathit{Predicted\ State\ Probability} represents the probabilities associated with Predicted State\mathit{Predicted\ State}. In other words, it shows the degree of confidence in the prediction. For this binary example, the range is 0.5≤Predicted State Probability≤10.5 \le \mathit{Predicted\ State\ Probability} \le 1. The lower endpoint is a tie between the two states, and the upper endpoint represents certainty.

The node Predicted State\mathit{Predicted\ State} is the state the network predicted given the available observations.

Finally, the binary node Correct\mathit{Correct} shows whether Predicted State\mathit{Predicted\ State} coincides with Actual State\mathit{Actual\ State}.

Interpretation

The benefit of this model becomes clear once you translate common questions about the performance of a predictive model into queries of the corresponding prediction analysis model.

For instance, we would be interested in how many of the patients who actually had Coronary Artery Disease were predicted as such. So, we set P(Actual State=Coronary Artery Disease)=100%P(\mathit{Actual\ State}=\mathrm{Coronary\ Artery\ Disease})=100\%.

Loading SVG...

The model correctly predicted 202 of the 216 actual cases of coronary artery disease (93.52%). BayesiaLab shows this percentage under Precision. To see the comparison, return to the original network, open Menus > Analysis > Network Performance > Target, evaluate all states and select Comprehensive Report.

The native confusion tables with 202 correct disease predictions, 94.3925% reliability and 93.5185% precision

Conversely, we can set P(Predicted State=Coronary Artery Disease)=100%P(\mathit{Predicted\ State}=\mathrm{Coronary\ Artery\ Disease})=100\%.

Loading SVG...

In the same report, Reliability answers the reverse question. Of the 214 records predicted as coronary artery disease, 202 had the condition (94.39%).

Similarly, any other cell in the Confusion Matrix above can be computed in the same way. Furthermore, we can pursue additional questions that cannot be easily obtained from any report.

For instance, we can examine the distributions associated with incorrect predictions by setting P(Correct=False)=100%P(\mathit{Correct}=\mathrm{False})=100\%.

Loading SVG...
Click to Zoom

Of the 26 incorrect predictions, 14 records (53.85%) had coronary artery disease. Across all 303 records, the corresponding share was 71.29%. Comparing these distributions helps identify which cases to examine when refining the model.

Workflow animation