public BarChart(final String title, final String xAxisLabel, final String yAxisLabel, final String[] categories) {
super(title, xAxisLabel, yAxisLabel);
this.dataset = new DefaultCategoryDataset();
this.chart = createChart(title, xAxisLabel, yAxisLabel, this.dataset);
this.plot = this.chart.getCategoryPlot();
this.categories = categories.clone();
addDefaultFormatting();
final CategoryAxis axis1 = this.plot.getDomainAxis();
axis1.setCategoryMargin(0.20);
BarRenderer renderer = (BarRenderer)this.plot.getRenderer();
renderer.setItemMargin(0.10);
}