public class TreeColorMapper extends ColorMapper
Tree
s.Modifier and Type | Field and Description |
---|---|
static String |
AVG_SPINE_DENSITY
Flag for "Average spine/varicosity density" mapping.
|
static String |
LENGTH
Flag for "Path length" mapping.
|
static String |
MEAN_RADIUS
Flag for "Path mean radius" mapping.
|
static String |
N_BRANCH_POINTS
Flag for "No. of branch points" mapping.
|
static String |
N_NODES
Flag for "No. of nodes" mapping.
|
static String |
N_SPINES
Flag for "No. of spines/varicosities" statistics.
|
static String |
NODE_RADIUS
Flag for "Node radius" mapping.
|
static String |
PATH_DISTANCE
Flag for "Path distance to soma" mapping.
|
static String |
PATH_FRAME
Flag for "Path frame" mapping.
|
static String |
PATH_ORDER
Flag for "Path order" mapping.
|
protected ArrayList<Path> |
paths |
static String |
SHOLL_COUNTS
Flag for "Sholl inters. (root centered)" mapping.
|
static String |
STRAHLER_NUMBER
Flag for "Horton-Strahler number" mapping.
|
static String |
TAG_FILENAME
Flag for "Tags/filename" mapping.
|
static String |
VALUES
Flag for "Node intensity values" mapping.
|
static String |
X_COORDINATES
Flag for "X coordinates" mapping.
|
static String |
Y_COORDINATES
Flag for "Y coordinates" mapping.
|
static String |
Z_COORDINATES
Flag for "Z coordinates" mapping.
|
colorTable, integerScale, max, min
Constructor and Description |
---|
TreeColorMapper()
Instantiates the mapper.
|
TreeColorMapper(Context context)
Instantiates the mapper.
|
Modifier and Type | Method and Description |
---|---|
Set<String> |
getAvailableLuts()
Gets the available LUTs.
|
ColorTable |
getColorTable(String lut) |
static List<String> |
getMetrics()
Gets the list of supported mapping metrics.
|
MultiViewer2D |
getMultiViewer()
Assembles a
Multi-pane viewer using all the Trees
mapped so far. |
protected String |
getNormalizedMeasurement(String measurement) |
static void |
main(String... args) |
void |
map(Collection<? extends PointInImage> points,
String measurement,
String lut)
Colorizes a collection of points after the specified measurement.
|
void |
map(Tree tree,
LinearProfileStats stats,
ColorTable colorTable)
Colorizes a tree using Sholl data.
|
void |
map(Tree tree,
String measurement,
ColorTable colorTable)
Colorizes a tree after the specified measurement.
|
void |
map(Tree tree,
String measurement,
String lut)
Colorizes a tree after the specified measurement.
|
protected void |
mapToProperty(String measurement,
ColorTable colorTable) |
void |
mapTrees(List<Tree> trees,
String lut)
Colorizes a list of trees, with each tree being assigned a LUT index.
|
protected String |
tryReallyHardToGuessMetric(String guess) |
getColor, getColorRGB, getColorTable, getMinMax, map, setMinMax
public static final String SHOLL_COUNTS
public static final String STRAHLER_NUMBER
public static final String PATH_ORDER
public static final String LENGTH
public static final String N_BRANCH_POINTS
public static final String N_NODES
public static final String N_SPINES
public static final String MEAN_RADIUS
public static final String AVG_SPINE_DENSITY
public static final String NODE_RADIUS
public static final String X_COORDINATES
public static final String Y_COORDINATES
public static final String Z_COORDINATES
public static final String VALUES
public static final String PATH_DISTANCE
public static final String TAG_FILENAME
public static final String PATH_FRAME
public TreeColorMapper(Context context)
context
- the SciJava application context providing the services
required by the classpublic TreeColorMapper()
public static List<String> getMetrics()
public ColorTable getColorTable(String lut)
protected void mapToProperty(String measurement, ColorTable colorTable)
public void map(Tree tree, LinearProfileStats stats, ColorTable colorTable)
tree
- the tree to be colorizedstats
- the LinearProfileStats instance containing the mapping
profile. if a polynomial fit has been successfully performed,
mapping is done against the fitted data, otherwise sampled
intersections are used.colorTable
- the color table specifying the color mapping. Null not
allowed.public void map(Tree tree, String measurement, ColorTable colorTable)
tree
- the tree to be mappedmeasurement
- the measurement (PATH_ORDER
}LENGTH
,
etc.)colorTable
- the color table specifying the color mapping. Null not
allowed.public void map(Collection<? extends PointInImage> points, String measurement, String lut)
points
- the points to be mappedmeasurement
- the measurement (Z_COORDINATES
, etc.). Note that
if points
do note encode a valid Tree. only
metrics applicable to coordinates are expected.lut
- the lookup table specifying the color mappingpublic void map(Tree tree, String measurement, String lut)
tree
- the tree to be mappedmeasurement
- the measurement (PATH_ORDER
}LENGTH
,
etc.)lut
- the lookup table specifying the color mappingpublic void mapTrees(List<Tree> trees, String lut)
trees
- the list of trees to be colorizedlut
- the lookup table specifying the color mappingpublic Set<String> getAvailableLuts()
public MultiViewer2D getMultiViewer()
Multi-pane viewer
using all the Trees
mapped so far.public static void main(String... args)
Copyright © 2015–2021 Fiji. All rights reserved.