public class ClusterStylingPolicy extends java.lang.Object implements ClassStylingPolicy
| Modifier and Type | Field and Description |
|---|---|
(package private) Clustering<?> |
clustering
Clustering in use.
|
(package private) it.unimi.dsi.fastutil.objects.Object2IntOpenHashMap<Cluster<?>> |
cmap
Map from cluster objects to color offsets.
|
(package private) it.unimi.dsi.fastutil.ints.IntArrayList |
colors
Colors
|
(package private) java.util.ArrayList<DBIDs> |
ids
Object IDs
|
| Constructor and Description |
|---|
ClusterStylingPolicy(Clustering<?> clustering,
StyleLibrary style)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
int |
classSize(int cnum)
Get the number of elements in the styling class.
|
Clustering<?> |
getClustering()
Get the clustering used by this styling policy
|
int |
getColorForDBID(DBIDRef id)
Get the color for an individual object.
|
int |
getMaxStyle()
Get the maximum style in use.
|
java.lang.String |
getMenuName()
Name to display in the menu.
|
int |
getMinStyle()
Get the minimum style in use.
|
int |
getStyleForCluster(Cluster<?> c)
Get the style number for a cluster.
|
int |
getStyleForDBID(DBIDRef id)
Get the style number for a particular object
|
DBIDIter |
iterateClass(int cnum)
Iterate over all objects from a given class.
|
java.util.ArrayList<DBIDs> ids
it.unimi.dsi.fastutil.objects.Object2IntOpenHashMap<Cluster<?>> cmap
it.unimi.dsi.fastutil.ints.IntArrayList colors
Clustering<?> clustering
public ClusterStylingPolicy(Clustering<?> clustering, StyleLibrary style)
clustering - Clustering to use.public int getStyleForDBID(DBIDRef id)
ClassStylingPolicygetStyleForDBID in interface ClassStylingPolicyid - Object IDpublic int getColorForDBID(DBIDRef id)
StylingPolicygetColorForDBID in interface StylingPolicyid - Object IDpublic int getMinStyle()
ClassStylingPolicygetMinStyle in interface ClassStylingPolicypublic int getMaxStyle()
ClassStylingPolicygetMaxStyle in interface ClassStylingPolicypublic DBIDIter iterateClass(int cnum)
ClassStylingPolicyiterateClass in interface ClassStylingPolicycnum - Class numberpublic int classSize(int cnum)
ClassStylingPolicyclassSize in interface ClassStylingPolicycnum - Class numberpublic Clustering<?> getClustering()
public int getStyleForCluster(Cluster<?> c)
c - Clusterpublic java.lang.String getMenuName()
VisualizationItemnull or empty string.getMenuName in interface VisualizationItemCopyright © 2019 ELKI Development Team. License information.