liveBook · Manning

Cost matrix

As explained in Build AI Drug Discovery Pipelines

A cost matrix specifies the cost assigned to each combination of predicted class and actual class.

A cost matrix assigns a cost to each combination of predicted class and actual class. In cost-sensitive learning, these costs weight each instance's loss so costly mistakes matter more. section 5.2.2

For binary classification, entries distinguish true negatives, false negatives, false positives, and true positives using the convention (predicted, actual). A useful matrix requires a problem context where decision costs can be quantified. section 5.2.2

Virtual screening

A false negative for an inhibitor can waste downstream drug-discovery resources, giving that error a measurable cost. Investment decisions provide another example when false positives have known monetary consequences. section 5.2.2

Constructing the matrix requires extra computation and reliable cost estimates. When those estimates are unavailable, class-balanced loss offers a simpler alternative by weighting classes inversely to their sample counts. section 5.2.2

Table 5.1 Cost matrix for cost-sensitive learning. Subscripts read (predicted, actual)
Predicted ↓ / Actual →
Actual Negative
Actual Positive
Predicted Negative
C00 (TN)
C01 (FN)
Predicted Positive
C10 (FP)
C11 (TP)

Use the binary matrix to inspect how predicted and actual classes map to TN, FN, FP, and TP costs. section 5.2.2

How Build AI Drug Discovery Pipelines covers it

How deep it goes
Defines the predicted-actual layout and application rationale, but does not provide a complete matrix-construction procedure.
Examples
Uses virtual screening and investment decisions to illustrate measurable false-negative and false-positive costs.
What it assumes
Assumes binary classification terminology such as predicted class, actual class, false positive, and false negative.
What you can do after
Apply cost-sensitive learning when misclassification consequences can be quantified.
How it connects
Connects cost-sensitive learning with class imbalance, false positives, false negatives, and class-balanced loss.

Also explained in

Compare how 2 books explain cost matrix →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Build AI Drug Discovery Pipelines. The section links point to the parts of the book it draws on.