List of usage examples for org.jfree.data.general HeatMapDataset getYValue
public double getYValue(int yIndex);
From source file:org.jfree.data.general.HeatMapUtilities.java
/** * Returns a dataset containing one series that holds a copy of the (y, z) * data from one column (x-index) of the specified dataset. * * @param dataset the dataset (<code>null</code> not permitted). * @param column the column (x) index./*from w w w . ja va 2 s. c o m*/ * @param seriesName the series name (<code>null</code> not permitted). * * @return The dataset. */ public static XYDataset extractColumnFromHeatMapDataset(HeatMapDataset dataset, int column, Comparable seriesName) { XYSeries series = new XYSeries(seriesName); int rows = dataset.getYSampleCount(); for (int r = 0; r < rows; r++) { series.add(dataset.getYValue(r), dataset.getZValue(column, r)); } XYSeriesCollection result = new XYSeriesCollection(series); return result; }