# 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 Object implements Style
Style subclass for kernel density plots.

Since:
  17 Feb 2015
Author:
  Mark Taylor

## Constructor Summary

Constructors
Constructor
Description
`KDenseStyle(Color color, FillMode fill, Stroke stroke, boolean isY, Kernel1dShape kernelShape, AbstractKernelDensityPlotter.KernelFigure kernelFigure, Combiner combiner, Unit unit, Cumulation cumulative, Normalisation norm)`
Constructor.

## Method Summary

Modifier and Type
Method
Description
`Kernel1d`
`createKernel(Axis xAxis, boolean xLog)`
Constructs a smoothing kernel suitable for this style.
`boolean`
`equals(Object o)`
`Cumulation`
`getCumulative()`
Returns cumulative mode.
`Icon`
`getLegendIcon()`
Returns an icon suitable for displaying in a legend for this style.
`Normalisation`
`getNormalisation()`
Returns normalisation mode.
`int`
`hashCode()`

### Methods inherited from class Object

`clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait`

## Constructor Details

### KDenseStyle

public KDenseStyle(Color color, FillMode fill, Stroke stroke, boolean isY, Kernel1dShape kernelShape, AbstractKernelDensityPlotter.KernelFigure kernelFigure, Combiner combiner, Unit unit, Cumulation cumulative, Normalisation norm)
Constructor.

Parameters:
  `color` - plot colour
  `fill` - fill mode
  `stroke` - line stroke, null for filled area
  `isY` - true to turn the plot sideways
  `kernelShape` - smoothing kernel shape
  `kernelFigure` - kernel configuration
  `combiner` - bin aggregation mode
  `unit` - axis unit scaling
  `cumulative` - are bins painted cumulatively
  `norm` - normalisation mode

## Method Details

### getCumulative

public Cumulation getCumulative()
Returns cumulative mode.

Returns:
  cumulative counting mode

### getNormalisation

public Normalisation getNormalisation()
Returns normalisation mode.

Returns:
  normalisation mode for count axis

### getLegendIcon

public Icon getLegendIcon()
Description copied from interface: `Style`
Returns an icon suitable for displaying in a legend for this style.

Specified by:
  `getLegendIcon` in interface `Style`

### createKernel

public Kernel1d createKernel(Axis xAxis, boolean xLog)
Constructs a smoothing kernel suitable for this style.

Parameters:
  `xAxis` - axis on which samples occur
  `xLog` - true for logarithmic x axis, false for linear
Returns:
  kernel

### hashCode

public int hashCode()

Overrides:
  `hashCode` in class `Object`

### equals

public boolean equals(Object o)

Overrides:
  `equals` in class `Object`