lucem_hist::intensity
Intensity classes: one measurement (a cell’s Nucleus: DAB OD mean, say) against one
threshold (negative / positive) or three (negative, 1+, 2+, 3+), and what a region reports
from them: Positive % (a labelling index such as Ki67’s) and the H-score (0–300).
IntensityThresholds
Section titled “IntensityThresholds”pub struct IntensityThresholdsFields
measurement: Stringthresholds: Vec<f64>: One threshold, or three increasing ones.filter: Option<String>: Only objects of this class (Tumor) get an intensity class.
Methods
pub fn class_of(&self, v: f64) -> IntensityClassImplements Clone, Debug, Deserialize, PartialEq, Serialize.
IntensitySummary
Section titled “IntensitySummary”pub struct IntensitySummaryFields
total: usize: Objects with an intensity class.negative: usizepositive: usizeone_plus: usizetwo_plus: usizethree_plus: usizepositive_percent: f64h_score: f64:1 · %1+ + 2 · %2+ + 3 · %3+(0–300). With one threshold there are no 1+ / 2+ / 3+ classes, so it stays 0.
Implements Clone, Copy, Debug, Default, Deserialize, PartialEq, Serialize.
Functions
Section titled “Functions”classify
Section titled “classify”pub fn classify(objects: &mut [HistObject], t: &IntensityThresholds) -> usizeSets the intensity class of the objects it applies to (their main class stays); the others lose theirs. How many were classified.
summarize
Section titled “summarize”pub fn summarize<'a>(objects: impl IntoIterator<Item = &'a HistObject>) -> IntensitySummary