title: How to set DateAxis TickUnit (Date Interval) in JavaFX?
body: <p>I'm developing a chart using JavaFX. I needed <code>DateAxis</code>, so I use
  <code>DateAxis</code> from <a href="http://www.programcreek.com/java-api-examples/index.php?source_dir=Corendon-master/src/nl/itopia/corendon/components/DateAxis.java" rel="nofollow noreferrer">this code</a>. The result is <a href="https://i.stack.imgur.com/TU2bH.jpg" rel="nofollow noreferrer">this</a>. But I want show 2 date
  interval, I didn't find solution. The result always show one day interval. This is my code. </p>
  
  <pre><code>public class Main extends Application {
  
  @Override
  public void start(Stage primaryStage) throws Exception {
  
      SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd HH-mm-ss");
      ObservableList&lt;XYChart.Series&lt;Date, Number&gt;&gt; series = FXCollections.observableArrayList();
  
      ObservableList&lt;XYChart.Data&lt;Date, Number&gt;&gt; series1Data = FXCollections.observableArrayList();
      series1Data.add(new XYChart.Data&lt;Date, Number&gt;(new GregorianCalendar(2018,1, 12).getTime(), 2));
      series1Data.add(new XYChart.Data&lt;Date, Number&gt;(new GregorianCalendar(2018, 1, 15).getTime(), 3));
  
      series1Data.add(new XYChart.Data&lt;Date, Number&gt;(new GregorianCalendar(2018, 1, 16).getTime(), 4));
  
  
      series.add(new XYChart.Series&lt;&gt;("Series1", series1Data));
  
      NumberAxis numberAxis = new NumberAxis();
      DateAxis dateAxis = new DateAxis();
      dateAxis.setAutoRanging(false);
      dateAxis.setLowerBound(new GregorianCalendar(2018,2, 12).getTime());
      dateAxis.setUpperBound(new GregorianCalendar(2018,2, 16).getTime());
      dateAxis.setTickLabelFormatter(new StringConverter&lt;Date&gt;() {
          @Override
          public String toString(Date object) {
              return simpleDateFormat.format(object);
          }
          @Override
          public Date fromString(String string) {
              return null;
          }
      });
  
      LineChart lineChart = new LineChart(dateAxis, numberAxis, series);
      Scene scene = new Scene(lineChart, 900, 400);
  
      primaryStage.setScene(scene);
      primaryStage.show();
  }
  
  public static void main(String[] args) {
      launch(args);
      }
  }
  </code></pre>
  
  <p>How can I do that?</p>