Package sc.fiji.snt.analysis.curation
Class CurationHistograms
java.lang.Object
sc.fiji.snt.analysis.curation.CurationHistograms
Factory for the small histogram buttons sitting next to threshold spinners in the Curation Assistant.
Clicking the button shows the distribution of the corresponding check's metric across the current
reconstruction(s), with a marker at the configured threshold and the flagged region lightly shaded.
- Author:
- Tiago Ferreira
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumDefines Which side of the threshold(s) constitutes a flagged value. -
Method Summary
Modifier and TypeMethodDescriptionstatic JButtonbutton(String checkName, Function<Collection<Path>, PlausibilityCheck.Measurements> measureFn, Supplier<Collection<Path>> pathsSnapshot, DoubleSupplier primaryThreshold, DoubleSupplier secondaryThreshold, CurationHistograms.Side side, Component parent) Histogram button supporting both single- and two-threshold checks.static JButtonbutton(String checkName, Function<Collection<Path>, PlausibilityCheck.Measurements> measureFn, Supplier<Collection<Path>> pathsSnapshot, DoubleSupplier threshold, CurationHistograms.Side side, Component parent) Single-sided histogram button (LEFT_FLAGGED or RIGHT_FLAGGED).
-
Method Details
-
button
public static JButton button(String checkName, Function<Collection<Path>, PlausibilityCheck.Measurements> measureFn, Supplier<Collection<Path>> pathsSnapshot, DoubleSupplier threshold, CurationHistograms.Side side, Component parent) Single-sided histogram button (LEFT_FLAGGED or RIGHT_FLAGGED).- Parameters:
checkName- short name used in the popup title and empty-state messagemeasureFn- function that produces the measurement set from a path collection; called on a background threadpathsSnapshot- supplier that returns a snapshot of the current paths; called on the EDT before the worker starts, so it can safely iterate the live path listthreshold- supplier of the current spinner value (called on EDT)side- which side of the threshold is flaggedparent- component used to position the empty-state dialog (nullable)- Returns:
- the small icon button, ready to be added to a row
-
button
public static JButton button(String checkName, Function<Collection<Path>, PlausibilityCheck.Measurements> measureFn, Supplier<Collection<Path>> pathsSnapshot, DoubleSupplier primaryThreshold, DoubleSupplier secondaryThreshold, CurationHistograms.Side side, Component parent) Histogram button supporting both single- and two-threshold checks. PasssecondaryThreshold == nullfor single-sided checks; pass both suppliers forCurationHistograms.Side.OUTSIDE_FLAGGED(e.g.,PlausibilityCheck.BranchAngle, which has min and max spinners).
-