Java Code Examples for org.jfree.data.xy.XYSeries#remove()
The following examples show how to use
org.jfree.data.xy.XYSeries#remove() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: XYSeriesTests.java From astor with GNU General Public License v2.0 | 6 votes |
/** * Some checks for the remove(int) method. */ public void testRemove2() { XYSeries s1 = new XYSeries("S1"); s1.add(1.0, 1.1); s1.add(2.0, 2.2); s1.add(3.0, 3.3); s1.add(4.0, 4.4); s1.add(5.0, 5.5); s1.add(6.0, 6.6); assertEquals(6, s1.getItemCount()); assertEquals(1.0, s1.getMinX(), EPSILON); assertEquals(6.0, s1.getMaxX(), EPSILON); assertEquals(1.1, s1.getMinY(), EPSILON); assertEquals(6.6, s1.getMaxY(), EPSILON); s1.remove(5); assertEquals(5, s1.getItemCount()); assertEquals(1.0, s1.getMinX(), EPSILON); assertEquals(5.0, s1.getMaxX(), EPSILON); assertEquals(1.1, s1.getMinY(), EPSILON); assertEquals(5.5, s1.getMaxY(), EPSILON); }
Example 2
Source File: XYSeriesTests.java From astor with GNU General Public License v2.0 | 6 votes |
/** * Simple test for the remove() method. */ public void testRemove() { XYSeries s1 = new XYSeries("Series 1"); s1.add(1.0, 1.0); s1.add(2.0, 2.0); s1.add(3.0, 3.0); assertEquals(3, s1.getItemCount()); s1.remove(new Double(2.0)); assertEquals(new Double(3.0), s1.getX(1)); s1.remove(0); assertEquals(new Double(3.0), s1.getX(0)); }
Example 3
Source File: XYSeriesTests.java From astor with GNU General Public License v2.0 | 5 votes |
/** * Simple test for the remove() method. */ public void testRemove() { XYSeries s1 = new XYSeries("Series 1"); s1.add(1.0, 1.0); s1.add(2.0, 2.0); s1.add(3.0, 3.0); assertEquals(3, s1.getItemCount()); s1.remove(new Double(2.0)); assertEquals(new Double(3.0), s1.getX(1)); s1.remove(0); assertEquals(new Double(3.0), s1.getX(0)); }