code: public static XYChart getChart(
        String chartTitle,
        String xTitle,
        String yTitle,
        String seriesName,
        double[] xData,
        double[] yData) {
  
      double[][] yData2d = {yData};
      if (seriesName == null) {
        return getChart(chartTitle, xTitle, yTitle, null, xData, yData2d);
      } else {
        return getChart(chartTitle, xTitle, yTitle, new String[] {seriesName}, xData, yData2d);
      }
    }
docs: Creates a Chart with default style
  
  @param chartTitle the Chart title
  @param xTitle The X-Axis title
  @param yTitle The Y-Axis title
  @param seriesName The name of the series
  @param xData An array containing the X-Axis data
  @param yData An array containing Y-Axis data
  @return a Chart Object