Package tech.molecules.leet.table.chart
Class ScatterPlotModel
- java.lang.Object
-
- tech.molecules.leet.table.chart.ScatterPlotModel
-
public class ScatterPlotModel extends Object
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classScatterPlotModel.NumericalDatasourceKeyedDataset<U>static interfaceScatterPlotModel.ScatterPlotListenerclassScatterPlotModel.SetClusteringAnnotationsActionstatic classScatterPlotModel.SetColorNumericalDatasourcestatic classScatterPlotModel.SetPointSizeAction
-
Constructor Summary
Constructors Constructor Description ScatterPlotModel(NexusTableModel ntm, org.jfree.data.general.KeyedValuesDataset x, org.jfree.data.general.KeyedValuesDataset y)ScatterPlotModel(NexusTableModel ntm, NumericalDatasource nd_x, NumericalDatasource nd_y)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddScatterPlotListener(JFreeChartScatterPlot.ScatterPlotListener li)org.jfree.chart.JFreeChartgetChart()Map<String,Double>getHighlightMap(Collection<String> highlight)Map<String,Double>getHighlightMap(org.jfree.chart.entity.EntityCollection entityCollection, org.jfree.chart.entity.EntityCollection toHighlight)intgetHighlightNNearestNeighbors()intgetIndexForKey(String key)StringgetKeyForIndex(int i)StringgetKeyForXYEntity(org.jfree.chart.entity.XYItemEntity entity)NexusTableModelgetNexusTableModel()static org.jfree.chart.entity.EntityCollectiongetNNearestEntities(org.jfree.chart.entity.EntityCollection entityCollection, int px, int py, int n)org.jfree.chart.plot.XYPlotgetXYPlot()org.jfree.chart.renderer.xy.XYShapeRenderergetXYShapeRenderer()static double[]java2dToChart(org.jfree.chart.ChartPanel cp, org.jfree.chart.plot.XYPlot plot, double px, double py)voidreinitPlot()voidremoveScatterPlotListener(JFreeChartScatterPlot.ScatterPlotListener li)voidsetColor(org.jfree.data.general.DefaultKeyedValuesDataset data_color)voidsetColorExpclicit(org.jfree.chart.renderer.PaintScale colors, Map<String,Integer> values)voidsetColormap(net.mahdilamb.colormap.Colormap colormap)voidsetColorValues(Map<String,Double> col)voidsetColorValues(NumericalDatasource nds)voidsetHighlight(Set<String> highlight, boolean fireEvent)voidsetHighlightNNearestNeighbors(int n)set to -1 to deactivatebooleansetMouseOverClass(NexusTableModel.SelectionType st)voidsetMultipleAnnotations(Map<String,List<Integer>> classes, Map<Integer,Paint> paints)voidsetRendererShapeSize(int size)voidsetSelection(Set<String> selection)Note: calling this method does NOT fire any events in ClusterAppModelvoidsetWithoutAxisAndLegend()
-
-
-
Constructor Detail
-
ScatterPlotModel
public ScatterPlotModel(NexusTableModel ntm, org.jfree.data.general.KeyedValuesDataset x, org.jfree.data.general.KeyedValuesDataset y)
-
ScatterPlotModel
public ScatterPlotModel(NexusTableModel ntm, NumericalDatasource nd_x, NumericalDatasource nd_y)
-
-
Method Detail
-
setMouseOverClass
public boolean setMouseOverClass(NexusTableModel.SelectionType st)
-
setColor
public void setColor(org.jfree.data.general.DefaultKeyedValuesDataset data_color)
-
setColorExpclicit
public void setColorExpclicit(org.jfree.chart.renderer.PaintScale colors, Map<String,Integer> values)
-
setColorValues
public void setColorValues(NumericalDatasource nds)
-
getNexusTableModel
public NexusTableModel getNexusTableModel()
-
setColormap
public void setColormap(net.mahdilamb.colormap.Colormap colormap)
-
getKeyForXYEntity
public String getKeyForXYEntity(org.jfree.chart.entity.XYItemEntity entity)
-
setHighlightNNearestNeighbors
public void setHighlightNNearestNeighbors(int n)
set to -1 to deactivate- Parameters:
n-
-
setSelection
public void setSelection(Set<String> selection)
Note: calling this method does NOT fire any events in ClusterAppModel- Parameters:
selection-
-
java2dToChart
public static double[] java2dToChart(org.jfree.chart.ChartPanel cp, org.jfree.chart.plot.XYPlot plot, double px, double py)
-
getHighlightMap
public Map<String,Double> getHighlightMap(Collection<String> highlight)
-
getHighlightMap
public Map<String,Double> getHighlightMap(org.jfree.chart.entity.EntityCollection entityCollection, org.jfree.chart.entity.EntityCollection toHighlight)
-
getNNearestEntities
public static org.jfree.chart.entity.EntityCollection getNNearestEntities(org.jfree.chart.entity.EntityCollection entityCollection, int px, int py, int n)
-
getHighlightNNearestNeighbors
public int getHighlightNNearestNeighbors()
-
addScatterPlotListener
public void addScatterPlotListener(JFreeChartScatterPlot.ScatterPlotListener li)
-
removeScatterPlotListener
public void removeScatterPlotListener(JFreeChartScatterPlot.ScatterPlotListener li)
-
getKeyForIndex
public String getKeyForIndex(int i)
-
getIndexForKey
public int getIndexForKey(String key)
-
getChart
public org.jfree.chart.JFreeChart getChart()
-
getXYPlot
public org.jfree.chart.plot.XYPlot getXYPlot()
-
reinitPlot
public void reinitPlot()
-
getXYShapeRenderer
public org.jfree.chart.renderer.xy.XYShapeRenderer getXYShapeRenderer()
-
setRendererShapeSize
public void setRendererShapeSize(int size)
-
setMultipleAnnotations
public void setMultipleAnnotations(Map<String,List<Integer>> classes, Map<Integer,Paint> paints)
- Parameters:
classes-paints-
-
setWithoutAxisAndLegend
public void setWithoutAxisAndLegend()
-
-