public class PathProfiler extends CommonDynamicCmd
Modifier and Type | Field and Description |
---|---|
static String |
CENTERLINE |
static String |
CIRCLE |
static String |
DISK |
static String |
SPHERE |
static String |
X_VALUES
Flag for retrieving distances from
getValues(Path) |
static String |
Y_VALUES
Flag for retrieving intensities from
getValues(Path) |
EMPTY_LABEL, HEADER_HTML, snt, sntService, statusService, ui, uiService
moduleService, pluginService
Constructor and Description |
---|
PathProfiler() |
PathProfiler(Path path,
Dataset dataset) |
PathProfiler(Path path,
ij.ImagePlus imp)
Instantiates a new Profiler from a single path
|
PathProfiler(Tree tree,
Dataset dataset) |
PathProfiler(Tree tree,
ij.ImagePlus imp)
Instantiates a new Profiler
|
Modifier and Type | Method and Description |
---|---|
void |
assignValues()
Calls
assignValues(Path) on the Paths of the profiled Tree |
void |
assignValues(int channel) |
void |
assignValues(Path p)
Retrieves pixel intensities at each node of the Path storing them as Path
values |
<T extends RealType<T>> |
assignValues(Path p,
int channel) |
Plot |
getPlot()
Gets the plot profile as an IJ1
Plot . |
Plot |
getPlot(int channel) |
Plot |
getPlot(Path path) |
Map<String,List<Double>> |
getValues(Path p)
Gets the profile for the specified path as a map of lists, with distances (or
indices) stored under
X_VALUES ("x-values") and intensities
under Y_VALUES ("y-values"). |
Map<String,List<Double>> |
getValues(Path p,
int channel) |
net.imagej.plot.XYPlot |
getXYPlot()
Gets the plot profile as an
PlotService plot. |
net.imagej.plot.XYPlot |
getXYPlot(int channel) |
static void |
main(String[] args) |
void |
run() |
void |
setFrame(int frame) |
void |
setMetric(ProfileProcessor.Metric metric) |
void |
setNodeIndicesAsDistances(boolean nodeIndices)
Sets whether the profile abscissae should be reported in real-word units
(the default) or node indices (zero-based).
|
void |
setRadius(int radius) |
void |
setShape(ProfileProcessor.Shape shape) |
cancel, cancel, error, init, msg, notifyExternalDataLoaded, notifyLoadingEnd, notifyLoadingStart, resetUI, resetUI, status
context, getCancelReason, getContext, getInfo, getInput, getOutput, isCanceled, saveInputs, setContext, setInput, setOutput, uncancel
getDelegateObject, getInputs, getOutputs, initialize, isInputResolved, isOutputResolved, preview, resolveInput, resolveOutput, setInputs, setOutputs, unresolveInput, unresolveOutput
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
addInput, addInput, addOutput, addOutput, removeInput, removeOutput
getDelegateObject, getInputs, getOutputs, initialize, isInputResolved, isOutputResolved, isResolved, preview, resolveInput, resolveOutput, setInputs, setOutputs, setResolved, unresolveInput, unresolveOutput
public static final String CIRCLE
public static final String DISK
public static final String SPHERE
public static final String CENTERLINE
public static final String X_VALUES
getValues(Path)
public static final String Y_VALUES
getValues(Path)
public PathProfiler()
public PathProfiler(Tree tree, ij.ImagePlus imp)
tree
- the Tree to be profiledimp
- the image from which pixel intensities will be retrieved. If
paths in the Tree are assigned different frames, it is assumed by
default that the active frame of the image defines the time-point
to be profiled. Note that no effort is made to ensure that the
image is suitable for profiling.public PathProfiler(Path path, ij.ImagePlus imp)
path
- the path to be profiledimp
- the image from which pixel intensities will be retrieved.Note
that no effort is made to ensure that the image is suitable for
profiling.public void setShape(ProfileProcessor.Shape shape)
public void setMetric(ProfileProcessor.Metric metric)
public void setRadius(int radius)
public void setFrame(int frame)
public void run()
run
in interface Runnable
run
in interface MutableModule
run
in class CommonDynamicCmd
public void assignValues() throws IllegalArgumentException
assignValues(Path)
on the Paths of the profiled TreeIllegalArgumentException
public void assignValues(int channel) throws IllegalArgumentException, ArrayIndexOutOfBoundsException
public void assignValues(Path p) throws IllegalArgumentException
values
p
- the Path to be profiledIllegalArgumentException
- if image does not contain the path's channelPath.setNodeValues(double[])
public <T extends RealType<T>> void assignValues(Path p, int channel) throws ArrayIndexOutOfBoundsException
ArrayIndexOutOfBoundsException
public void setNodeIndicesAsDistances(boolean nodeIndices)
getValues(Path)
, getPlot()
or getXYPlot()
.nodeIndices
- If true, distances will be reported as indices.public Map<String,List<Double>> getValues(Path p)
X_VALUES
("x-values") and intensities
under Y_VALUES
("y-values").p
- the path to be profiledpublic Map<String,List<Double>> getValues(Path p, int channel) throws IllegalArgumentException
IllegalArgumentException
public Plot getPlot() throws IllegalArgumentException, ArrayIndexOutOfBoundsException
Plot
.IllegalArgumentException
ArrayIndexOutOfBoundsException
public Plot getPlot(int channel) throws IllegalArgumentException, ArrayIndexOutOfBoundsException
public net.imagej.plot.XYPlot getXYPlot()
PlotService
plot. Requires
DynamicCommand.setContext(org.scijava.Context)
to be called beforehand.public net.imagej.plot.XYPlot getXYPlot(int channel) throws IllegalArgumentException
IllegalArgumentException
public static void main(String[] args)
Copyright © 2015–2021 Fiji. All rights reserved.