Class QuickChart


  • public final class QuickChart
    extends Object
    A convenience class for making Charts with one line of code
    Author:
    timmolter
    • Method Detail

      • getChart

        public static XYChart getChart​(String chartTitle,
                                       String xTitle,
                                       String yTitle,
                                       String seriesName,
                                       double[] xData,
                                       double[] yData)
        Creates a Chart with default style
        Parameters:
        chartTitle - the Chart title
        xTitle - The X-Axis title
        yTitle - The Y-Axis title
        seriesName - The name of the series
        xData - An array containing the X-Axis data
        yData - An array containing Y-Axis data
        Returns:
        a Chart Object
      • getChart

        public static XYChart getChart​(String chartTitle,
                                       String xTitle,
                                       String yTitle,
                                       String[] seriesNames,
                                       double[] xData,
                                       double[][] yData)
        Creates a Chart with multiple Series for the same X-Axis data with default style
        Parameters:
        chartTitle - the Chart title
        xTitle - The X-Axis title
        yTitle - The Y-Axis title
        seriesNames - An array of the name of the multiple series
        xData - An array containing the X-Axis data
        yData - An array of double arrays containing multiple Y-Axis data
        Returns:
        a Chart Object
      • getChart

        public static XYChart getChart​(String chartTitle,
                                       String xTitle,
                                       String yTitle,
                                       String seriesName,
                                       List<? extends Number> xData,
                                       List<? extends Number> yData)
        Creates a Chart with default style
        Parameters:
        chartTitle - the Chart title
        xTitle - The X-Axis title
        yTitle - The Y-Axis title
        seriesName - The name of the series
        xData - A Collection containing the X-Axis data
        yData - A Collection containing Y-Axis data
        Returns:
        a Chart Object