Skip to main content
A Score answer. score is a number and can sit between two levels. [ScoreAnswer.probabilities], [ScoreAnswer.nearest], and [ScoreAnswer.bounds] use the level string you passed in.

Constructor

Returns

ScoreAnswer

Properties

number
required
0–1 summary of how peaked [ScoreAnswer.probabilities] is.
Record<string, number>
required
Probability per level, keyed by the level texts the caller supplied.
number
required
Continuous position on the level spectrum (0.0 = first level).

Methods

bounds()

The levels flanking [ScoreAnswer.score] (equal when the score sits on a level exactly).

Returns

[string, string]

nearest()

The level closest to [ScoreAnswer.score].

Returns

string