afreechart/src/main/java/org/afree/chart/ChartFactory.java
/**
         * Creates a scatter plot with default settings.  The chart object
         * returned by this method uses an {@link XYPlot} instance as the plot,
         * with a {@link NumberAxis} for the domain axis, a  {@link NumberAxis}
         * as the range axis, and an {@link XYLineAndShapeRenderer} as the
         * renderer.
         *
         * @param title  the chart title (<code>null</code> permitted).
         * @param xAxisLabel  a label for the X-axis (<code>null</code> permitted).
         * @param yAxisLabel  a label for the Y-axis (<code>null</code> permitted).
         * @param dataset  the dataset for the chart (<code>null</code> permitted).
         * @param orientation  the plot orientation (horizontal or vertical)
         *                     (<code>null</code> NOT permitted).
         * @param legend  a flag specifying whether or not a legend is required.
         * @param tooltips  configure chart to generate tool tips?
         * @param urls  configure chart to generate URLs?
         *
         * @return A scatter plot.
         */
Creates a scatter plot with default settings.  The chart object
returned by this method uses an  XYPlot instance as the plot,
with a  NumberAxis for the domain axis, a   NumberAxis
as the range axis, and an  XYLineAndShapeRenderer as the
renderer.

@param title  the chart title (null permitted).
@param xAxisLabel  a label for the X-axis (null permitted).
@param yAxisLabel  a label for the Y-axis (null permitted).
@param dataset  the dataset for the chart (null permitted).
@param orientation  the plot orientation (horizontal or vertical)
(null NOT permitted).
@param legend  a flag specifying whether or not a legend is required.
@param tooltips  configure chart to generate tool tips.

@return A scatter plot.
Creates a scatter plot with default settings . The chart object returned by this method uses an XYPlot instance as the plot with a NumberAxis for the domain axis a NumberAxis as the range axis and an XYLineAndShapeRenderer as the renderer . @param title the chart title ( null permitted ) . @param xAxisLabel a label for the X - axis ( null permitted ) . @param yAxisLabel a label for the Y - axis ( null permitted ) . @param dataset the dataset for the chart ( null permitted ) . @param orientation the plot orientation ( horizontal or vertical ) ( null NOT permitted ) . @param legend a flag specifying whether or not a legend is required . @param tooltips configure chart to generate tool tips . @return A scatter plot .
public static AFreeChart createScatterPlot(String title, String xAxisLabel,
                String yAxisLabel, XYDataset dataset, PlotOrientation orientation,
                boolean legend, boolean tooltips, boolean urls) {
            if (orientation == null) {
                throw new IllegalArgumentException("Null 'orientation' argument.");
            }
            NumberAxis xAxis = new NumberAxis(xAxisLabel);
            xAxis.setAutoRangeIncludesZero(false);
            NumberAxis yAxis = new NumberAxis(yAxisLabel);
            yAxis.setAutoRangeIncludesZero(false);
            XYPlot plot = new XYPlot(dataset, xAxis, yAxis, null);
            XYURLGenerator urlGenerator = null;
            if (urls) {
                urlGenerator = new StandardXYURLGenerator();
            XYItemRenderer renderer = new XYLineAndShapeRenderer(false, true);
            renderer.setBaseToolTipGenerator(toolTipGenerator);
            renderer.setURLGenerator(urlGenerator);
            plot.setRenderer(renderer);
            plot.setOrientation(orientation);
            AFreeChart chart = new AFreeChart(title, AFreeChart.DEFAULT_TITLE_FONT,
                    plot, legend);
            currentTheme.apply(chart);
            return chart;
        }
public static AFreeChart createScatterPlot ( String title , String xAxisLabel , String yAxisLabel , XYDataset dataset , PlotOrientation orientation , boolean legend , boolean tooltips , boolean urls ) { if ( orientation == null ) { throw new IllegalArgumentException ( "Null 'orientation' argument." ) ; } NumberAxis xAxis = new NumberAxis ( xAxisLabel ) ; xAxis . setAutoRangeIncludesZero ( false ) ; NumberAxis yAxis = new NumberAxis ( yAxisLabel ) ; yAxis . setAutoRangeIncludesZero ( false ) ; XYPlot plot = new XYPlot ( dataset , xAxis , yAxis , null ) ; XYItemRenderer renderer = new XYLineAndShapeRenderer ( false , true ) ; plot . setRenderer ( renderer ) ; plot . setOrientation ( orientation ) ; AFreeChart chart = new AFreeChart ( title , AFreeChart . DEFAULT_TITLE_FONT , plot , legend ) ; return chart ; }
Creates a scatter plot with default settings.
Creates a scatter plot with default settings .
//        XYToolTipGenerator toolTipGenerator = null; //        if (tooltips) { //            toolTipGenerator = new StandardXYToolTipGenerator(); //        } // //        XYURLGenerator urlGenerator = null; //        if (urls) { //            urlGenerator = new StandardXYURLGenerator(); //        } //        renderer.setBaseToolTipGenerator(toolTipGenerator); //        renderer.setURLGenerator(urlGenerator); //        currentTheme.apply(chart);