/** * Plot plot. * * @param pts the pts * @return the plot */ public Plot plot(final double[][] pts) { Plot plot; switch (type) { case Scatter: plot = new ScatterPlot(pts); plot.setID(name); plot.setColor(color); return plot; case Line: plot = new LinePlot(pts); plot.setID(name); plot.setColor(color); return plot; default: throw new IllegalStateException(type.toString()); } }
/** * Plot plot. * * @param pts the pts * @return the plot */ public Plot plot(final double[][] pts) { Plot plot; switch (type) { case Scatter: plot = new ScatterPlot(pts); plot.setID(name); plot.setColor(color); return plot; case Line: plot = new LinePlot(pts); plot.setID(name); plot.setColor(color); return plot; default: throw new IllegalStateException(type.toString()); } }
/** * Plot plot. * * @param pts the pts * @return the plot */ public Plot plot(final double[][] pts) { Plot plot; switch (type) { case Scatter: plot = new ScatterPlot(pts); plot.setID(name); plot.setColor(color); return plot; case Line: plot = new LinePlot(pts); plot.setID(name); plot.setColor(color); return plot; default: throw new IllegalStateException(type.toString()); } }