When some ticks are hidden (e.g., only 2, 4, 6, 8, 12 x-ticks are shown), bars are not placed at the correct x-position.
For example, this code:
public class XChartBug {
public static void main(String[] args) {
int[] x = new int[] {0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12};
int[] y = new int[] {1, 0, 1, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0};
Chart chart = new ChartBuilder().chartType(ChartType.Bar).width(640).height(480).build();
chart.addSeries("test", x, y);
chart.getStyleManager().setLegendVisible(false);
new SwingWrapper(chart).displayChart();
}
}
produces the plot:

By dropping the last bar, all x-ticks are shown, and the placement of bars is correct:

When some ticks are hidden (e.g., only 2, 4, 6, 8, 12 x-ticks are shown), bars are not placed at the correct x-position.
For example, this code:
produces the plot:
By dropping the last bar, all x-ticks are shown, and the placement of bars is correct: