Class DensityScatterPlot
- java.lang.Object
-
- adams.core.logging.LoggingObject
-
- adams.core.logging.CustomLoggingLevelObject
-
- adams.core.option.AbstractOptionHandler
-
- adams.gui.visualization.jfreechart.chart.AbstractChartGenerator<T>
-
- adams.gui.visualization.jfreechart.chart.AbstractChartGeneratorWithAxisLabels<org.jfree.data.xy.XYDataset>
-
- adams.gui.visualization.jfreechart.chart.DensityScatterPlot
-
- All Implemented Interfaces:
Destroyable
,GlobalInfoSupporter
,LoggingLevelHandler
,LoggingSupporter
,OptionHandler
,QuickInfoSupporter
,SizeOfHandler
,Serializable
public class DensityScatterPlot extends AbstractChartGeneratorWithAxisLabels<org.jfree.data.xy.XYDataset>
Generates a scatter plot from XY data.- Author:
- FracPete (fracpete at waikato dot ac dot nz)
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected double
m_Bandwidth
the bandwidth.protected ColorGradientGenerator
m_Generator
the color gradient generator.protected DensityPlotXYItemRenderer.DensityMode
m_Mode
how to calculate the density.protected int
m_NumBins
the number of bins to generate on X and Y.protected Orientation
m_Orientation
the plot orientation.-
Fields inherited from class adams.gui.visualization.jfreechart.chart.AbstractChartGeneratorWithAxisLabels
m_LabelX, m_LabelY
-
Fields inherited from class adams.gui.visualization.jfreechart.chart.AbstractChartGenerator
m_Legend, m_Title, m_ToolTips
-
Fields inherited from class adams.core.option.AbstractOptionHandler
m_OptionManager
-
Fields inherited from class adams.core.logging.LoggingObject
m_Logger, m_LoggingIsEnabled, m_LoggingLevel
-
-
Constructor Summary
Constructors Constructor Description DensityScatterPlot()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
bandwidthTipText()
Returns the tip text for this property.protected org.jfree.chart.renderer.PaintScale
createPaintScale(double min, double max)
Creates the paintscale to use.void
defineOptions()
Adds options to the internal list of options.protected org.jfree.chart.JFreeChart
doGenerate(org.jfree.data.xy.XYDataset data)
Performs the actual generation of the chart.String
generatorTipText()
Returns the tip text for this property.double
getBandwidth()
Returns the bandwidth for kernel density estimates.ColorGradientGenerator
getGenerator()
Returns the color generator.DensityPlotXYItemRenderer.DensityMode
getMode()
Returns the mode to use.int
getNumBins()
Returns the number of bins to generate on X and Y axis.Orientation
getOrientation()
Returns the orientation for the plot.String
globalInfo()
Returns a string describing the object.String
modeTipText()
Returns the tip text for this property.String
numBinsTipText()
Returns the tip text for this property.String
orientationTipText()
Returns the tip text for this property.void
setBandwidth(double value)
Sets the bandwidth for kernel density estimates.void
setGenerator(ColorGradientGenerator value)
Sets the color generator.void
setMode(DensityPlotXYItemRenderer.DensityMode value)
Sets the mode to use.void
setNumBins(int value)
Sets the number of bins to generate on X and Y axis.void
setOrientation(Orientation value)
Sets the orientation for the plot.-
Methods inherited from class adams.gui.visualization.jfreechart.chart.AbstractChartGeneratorWithAxisLabels
getLabelX, getLabelY, getQuickInfo, labelXTipText, labelYTipText, setLabelX, setLabelY
-
Methods inherited from class adams.gui.visualization.jfreechart.chart.AbstractChartGenerator
check, generate, getLegend, getTitle, getToolTips, legendTipText, setLegend, setTitle, setToolTips, titleTipText, toolTipsTipText
-
Methods inherited from class adams.core.option.AbstractOptionHandler
cleanUpOptions, destroy, finishInit, getDefaultLoggingLevel, getOptionManager, initialize, loggingLevelTipText, newOptionManager, reset, setLoggingLevel, toCommandLine, toString
-
Methods inherited from class adams.core.logging.LoggingObject
configureLogger, getLogger, getLoggingLevel, initializeLogging, isLoggingEnabled, sizeOf
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface adams.core.logging.LoggingLevelHandler
getLoggingLevel
-
-
-
-
Field Detail
-
m_Mode
protected DensityPlotXYItemRenderer.DensityMode m_Mode
how to calculate the density.
-
m_NumBins
protected int m_NumBins
the number of bins to generate on X and Y.
-
m_Bandwidth
protected double m_Bandwidth
the bandwidth.
-
m_Generator
protected ColorGradientGenerator m_Generator
the color gradient generator.
-
m_Orientation
protected Orientation m_Orientation
the plot orientation.
-
-
Method Detail
-
globalInfo
public String globalInfo()
Returns a string describing the object.- Specified by:
globalInfo
in interfaceGlobalInfoSupporter
- Specified by:
globalInfo
in classAbstractOptionHandler
- Returns:
- a description suitable for displaying in the gui
-
defineOptions
public void defineOptions()
Adds options to the internal list of options.- Specified by:
defineOptions
in interfaceOptionHandler
- Overrides:
defineOptions
in classAbstractChartGeneratorWithAxisLabels<org.jfree.data.xy.XYDataset>
-
setMode
public void setMode(DensityPlotXYItemRenderer.DensityMode value)
Sets the mode to use.- Parameters:
value
- the mode
-
getMode
public DensityPlotXYItemRenderer.DensityMode getMode()
Returns the mode to use.- Returns:
- the mode
-
modeTipText
public String modeTipText()
Returns the tip text for this property.- Returns:
- tip text for this property suitable for displaying in the GUI or for listing the options.
-
setNumBins
public void setNumBins(int value)
Sets the number of bins to generate on X and Y axis.- Parameters:
value
- the number of bins
-
getNumBins
public int getNumBins()
Returns the number of bins to generate on X and Y axis.- Returns:
- the number of bins
-
numBinsTipText
public String numBinsTipText()
Returns the tip text for this property.- Returns:
- tip text for this property suitable for displaying in the GUI or for listing the options.
-
setBandwidth
public void setBandwidth(double value)
Sets the bandwidth for kernel density estimates.- Parameters:
value
- the bandwidth
-
getBandwidth
public double getBandwidth()
Returns the bandwidth for kernel density estimates.- Returns:
- the bandwidth
-
bandwidthTipText
public String bandwidthTipText()
Returns the tip text for this property.- Returns:
- tip text for this property suitable for displaying in the GUI or for listing the options.
-
setGenerator
public void setGenerator(ColorGradientGenerator value)
Sets the color generator.- Parameters:
value
- the generator
-
getGenerator
public ColorGradientGenerator getGenerator()
Returns the color generator.- Returns:
- the generator
-
generatorTipText
public String generatorTipText()
Returns the tip text for this property.- Returns:
- tip text for this property suitable for displaying in the GUI or for listing the options.
-
setOrientation
public void setOrientation(Orientation value)
Sets the orientation for the plot.- Parameters:
value
- the orientation
-
getOrientation
public Orientation getOrientation()
Returns the orientation for the plot.- Returns:
- the orientation
-
orientationTipText
public String orientationTipText()
Returns the tip text for this property.- Returns:
- tip text for this property suitable for displaying in the GUI or for listing the options.
-
createPaintScale
protected org.jfree.chart.renderer.PaintScale createPaintScale(double min, double max)
Creates the paintscale to use.- Returns:
- the scale
-
doGenerate
protected org.jfree.chart.JFreeChart doGenerate(org.jfree.data.xy.XYDataset data)
Performs the actual generation of the chart.- Specified by:
doGenerate
in classAbstractChartGenerator<org.jfree.data.xy.XYDataset>
- Parameters:
data
- the data to use- Returns:
- the chart
-
-