mlquantify.adjust_counting#

Adjust Counting Methods#

CC

Classify and Count (CC) quantifier.

PCC

Probabilistic Classify and Count (PCC) quantifier.

FM

Friedman Method for quantification adjustment.

AC

Adjusted Count method.

PAC

Probabilistic Adjusted Count (PAC) method.

TAC

Threshold Adjusted Count (TAC) — baseline threshold correction.

TX

Threshold X method — threshold where \(\text{TPR} + \text{FPR} = 1\).

TMAX

Threshold MAX method — threshold maximizing \(\text{TPR} - \text{FPR}\).

T50

T50 — selects threshold where \(\text{TPR} = 0.5\).

MS

Median Sweep (MS) — median prevalence estimate across all thresholds.

MS2

MS2 — Median Sweep variant constraining \(|\text{TPR} - \text{FPR}| > 0.25\).

CDE

CDE-Iterate for binary classification prevalence estimation.

evaluate_thresholds

Evaluate a range of classification thresholds to compute the corresponding True Positive Rate (TPR) and False Positive Rate (FPR) for a binary quantification task.

compute_tpr

Compute the True Positive Rate (Recall) for a binary classification task.

compute_fpr

Compute the False Positive Rate for a binary classification task.

compute_table

Compute the confusion matrix table for a binary classification task.