A chance-corrected agreement rate on a two-by-two table. Read against the observed response it
is a skill score beside tss(); read between two models' decisions on the same units it says
where the two part company.
Value
For kappa_score(), one number. For decision_threshold(), the cut itself, applied as
p >= threshold. For model_agreement(), a one-row data frame carrying the agreement kappa
between two models cut by the same rule, the share of units they decide differently, and how
often each is the one that is right there.
Details
Kappa is read at a threshold rather than maximised over one, so the rule that picks the
threshold is part of the statistic. "youden" is the operating point tss() is defined at and
inherits its selection bias; "kappa" maximises kappa itself and inherits the analogous bias;
"prevalence" cuts at the observed presence rate, which selects nothing from the labels and is
the rule to read an absolute level at.