OptionalzOptionallabelOrdinal level name announced in place of the raw numeric y, for a chart
whose y axis is a category rather than a magnitude — a hypnogram's sleep
stages, a Likert response, a severity grade. y stays numeric because it
drives sonification, braille and the min/max range, so the human-readable
name has to travel alongside it.
An empty string counts as absent, so a producer that emits '' for an
unnamed level gets the numeric announcement rather than a blank one.
Omitting it entirely is the right shape for a continuous y.
OptionalyLower bound of the uncertainty around y, when the chart draws one.
A fitted curve almost always comes with a band, and it is the reason the
curve is drawn rather than a plain line: geom_smooth(se = TRUE) and
sns.regplot both default to one. Carried on the sample rather than in a
layer of its own so a reader hears the value and its interval at the same
x — the comparison a band exists for is whether the trend is
distinguishable from flat, and that cannot be made by navigating two
layers in turn.
Named to match ErrorBarPoint, so a producer that already computes an interval emits the same keys wherever it puts them.
Both bounds are optional and independent: a one-sided interval is a real chart, and a sample missing its bounds still carries its value.
OptionalyUpper bound of the uncertainty around y. See LinePoint.yMin.
The recall at this threshold, from 0 to 1.
The precision at this threshold, from 0 to 1, or null for a gap.
OptionalthresholdThe decision threshold this point was scored at.
The one number a reader can act on: without it the reader learns the
rates but not how to get them. Optional because a curve drawn from rates
alone is still a precision-recall curve -- and because
precision_recall_curve returns one threshold fewer than points, the
last point (recall 0, precision 1) having none.
OptionalprevalenceThe share of positives in the data this curve was scored on: the precision a classifier that guesses keeps at every recall, and so the height of the chart's chance baseline.
Read from the first point of the curve that declares one, the way z
names a series. When no point declares it, the baseline is not said: it
cannot be recovered from the points with confidence.
OptionalapThe average precision of this curve, as the producer computed it.
Read from the first point of the curve that declares one. When no point
declares it, it is measured from the curve's own points the way
sklearn.metrics.average_precision_score computes it: the sum, over
each rise in recall, of the rise times the precision at its top.
One point of a precision-recall curve: the recall a classifier reaches and the precision it keeps at one decision threshold.
A precision-recall layer is
PrCurvePoint[][], one array per curve, so several classifiers (or the classes of one, or the runs TensorBoard's PR Curves dashboard overlays) are compared in one layer the way a multi-line layer holds several series;znames the curve, as it names a line. Both rates are fractions of one. Listed in any order --precision_recall_curvereturns them from a recall of 1 down to 0 -- since the average precision is measured over the points sorted byx.Unlike a ROC curve, the chart is not read against a diagonal: a classifier that guesses keeps a precision equal to the share of positives in the data, at every recall. That share is the curve's
prevalence, and the baseline it draws is a horizontal line.Example