Class AbstractKernelDensityPlotter.KDenseStyle
- java.lang.Object
-
- uk.ac.starlink.ttools.plot2.layer.AbstractKernelDensityPlotter.KDenseStyle
-
- All Implemented Interfaces:
Style
- Enclosing class:
- AbstractKernelDensityPlotter
public static class AbstractKernelDensityPlotter.KDenseStyle extends java.lang.Object implements Style
Style subclass for kernel density plots.
-
-
Constructor Summary
Constructors Constructor Description KDenseStyle(java.awt.Color color, FillMode fill, java.awt.Stroke stroke, Kernel1dShape kernelShape, AbstractKernelDensityPlotter.KernelFigure kernelFigure, Combiner combiner, Unit unit, boolean isCumulative, Normalisation norm)Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Kernel1dcreateKernel(Axis xAxis, boolean xLog)Constructs a smoothing kernel suitable for this style.booleanequals(java.lang.Object o)javax.swing.IcongetLegendIcon()Returns an icon suitable for displaying in a legend for this style.NormalisationgetNormalisation()Returns normalisation mode.inthashCode()booleanisCumulative()Returns cumulative flag.
-
-
-
Constructor Detail
-
KDenseStyle
public KDenseStyle(java.awt.Color color, FillMode fill, java.awt.Stroke stroke, Kernel1dShape kernelShape, AbstractKernelDensityPlotter.KernelFigure kernelFigure, Combiner combiner, Unit unit, boolean isCumulative, Normalisation norm)Constructor.- Parameters:
color- plot colourfill- fill modestroke- line stroke, null for filled areakernelShape- smoothing kernel shapekernelFigure- kernel configurationcombiner- bin aggregation modeunit- axis unit scalingisCumulative- are bins painted cumulativelynorm- normalisation mode
-
-
Method Detail
-
isCumulative
public boolean isCumulative()
Returns cumulative flag.- Returns:
- true iff counts are cumulative
-
getNormalisation
public Normalisation getNormalisation()
Returns normalisation mode.- Returns:
- normalisation mode for count axis
-
getLegendIcon
public javax.swing.Icon getLegendIcon()
Description copied from interface:StyleReturns an icon suitable for displaying in a legend for this style.- Specified by:
getLegendIconin interfaceStyle
-
createKernel
public Kernel1d createKernel(Axis xAxis, boolean xLog)
Constructs a smoothing kernel suitable for this style.- Parameters:
xAxis- axis on which samples occurxLog- true for logarithmic x axis, false for linear- Returns:
- kernel
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equalsin classjava.lang.Object
-
-