/** * Returns the data value for a chip. * * @param chipx the x-index. * @param chipy the y-index. * * @return The data value. */ public Number getChipValue(int chipx, int chipy) { return getChipValue(new Integer(chipx), new Integer(chipy)); }
/** * Returns the number of unique values. * * @return The number of unique values. */ public int getUniqueValueCount() { return getUniqueValues().size(); }
/** * Sets a value in the dataset and updates min and max value entries. * * @param value the value. * @param chipx the x-index. * @param chipy the y-index. */ public void setValue(Number value, Comparable chipx, Comparable chipy) { this.data.setValue(value, chipx, chipy); if (isMaxValue(value)) { this.maxValue = (Double) value; } if (isMinValue(value)) { this.minValue = (Double) value; } }
double space = 1d; if (this.dataset != null) { xchips = this.dataset.getMaxChipX() + 2; ychips = this.dataset.getMaxChipY() + 2; space = this.dataset.getChipSpace(); chip.setFrame(upperLeftX, upperLeftY, chipWidth, chipHeight); g2.setColor(Color.WHITE); if (this.dataset.getChipValue(x - 1, ychips - y - 1) != null) { g2.setPaint( this.renderer.getChipColor( this.dataset.getChipValue(x - 1, ychips - y - 1)
/** * Sets the dataset used by the plot and sends a {@link PlotChangeEvent} * to all registered listeners. * * @param dataset the dataset (<code>null</code> permitted). */ public void setDataset(WaferMapDataset dataset) { // if there is an existing dataset, remove the plot from the list of // change listeners... if (this.dataset != null) { this.dataset.removeChangeListener(this); } // set the new dataset, and register the chart as a change listener... this.dataset = dataset; if (dataset != null) { setDatasetGroup(dataset.getGroup()); dataset.addChangeListener(this); } // send a dataset change event to self to trigger plot change event datasetChanged(new DatasetChangeEvent(this, dataset)); }
Number dataMin = data.getMinValue(); Number dataMax = data.getMaxValue(); Set uniqueValues = data.getUniqueValues(); if (uniqueValues.size() <= this.paintLimit) { int count = 0; // assign a color for each unique value
/** * Creates a new plot. * * @param dataset the dataset ({@code null} permitted). * @param renderer the renderer ({@code null} permitted). */ public WaferMapPlot(WaferMapDataset dataset, WaferMapRenderer renderer) { super(); this.orientation = PlotOrientation.VERTICAL; this.dataset = dataset; if (dataset != null) { dataset.addChangeListener(this); } this.renderer = renderer; if (renderer != null) { renderer.setPlot(this); renderer.addChangeListener(this); } }
double space = 1d; if (this.dataset != null) { xchips = this.dataset.getMaxChipX() + 2; ychips = this.dataset.getMaxChipY() + 2; space = this.dataset.getChipSpace(); chip.setFrame(upperLeftX, upperLeftY, chipWidth, chipHeight); g2.setColor(Color.white); if (this.dataset.getChipValue(x - 1, ychips - y - 1) != null) { g2.setPaint( this.renderer.getChipColor( this.dataset.getChipValue(x - 1, ychips - y - 1)
/** * Sets the dataset used by the plot and sends a {@link PlotChangeEvent} * to all registered listeners. * * @param dataset the dataset ({@code null} permitted). */ public void setDataset(WaferMapDataset dataset) { // if there is an existing dataset, remove the plot from the list of // change listeners... if (this.dataset != null) { this.dataset.removeChangeListener(this); } // set the new dataset, and register the chart as a change listener... this.dataset = dataset; if (dataset != null) { setDatasetGroup(dataset.getGroup()); dataset.addChangeListener(this); } // send a dataset change event to self to trigger plot change event datasetChanged(new DatasetChangeEvent(this, dataset)); }
Number dataMin = data.getMinValue(); Number dataMax = data.getMaxValue(); Set uniqueValues = data.getUniqueValues(); if (uniqueValues.size() <= this.paintLimit) { int count = 0; // assign a color for each unique value
/** * Creates a new plot. * * @param dataset the dataset (<code>null</code> permitted). * @param renderer the renderer (<code>null</code> permitted). */ public WaferMapPlot(WaferMapDataset dataset, WaferMapRenderer renderer) { super(); this.orientation = PlotOrientation.VERTICAL; this.dataset = dataset; if (dataset != null) { dataset.addChangeListener(this); } this.renderer = renderer; if (renderer != null) { renderer.setPlot(this); renderer.addChangeListener(this); } }
/** * Sets a value in the dataset and updates min and max value entries. * * @param value the value. * @param chipx the x-index. * @param chipy the y-index. */ public void setValue(Number value, Comparable chipx, Comparable chipy) { this.data.setValue(value, chipx, chipy); if (isMaxValue(value)) { this.maxValue = (Double) value; } if (isMinValue(value)) { this.minValue = (Double) value; } }
/** * Returns the data value for a chip. * * @param chipx the x-index. * @param chipy the y-index. * * @return The data value. */ public Number getChipValue(int chipx, int chipy) { return getChipValue(new Integer(chipx), new Integer(chipy)); }
/** * Returns the number of unique values. * * @return The number of unique values. */ public int getUniqueValueCount() { return getUniqueValues().size(); }