I've created a DefaultCategoryDataSet with several categories and series. The Line and Bar charts created with this dataset displays as I would expect it, with the categories along the x-axis and the multiple series along the y-axis. However, if I use the same exact dataset with a pie chart I get one pie for each series. The pies are divided up by category. I would have expected this to be the other way around: one pie for each category and the pies are subdivided by series. Is this a bug or did I misunderstand how this is being done.
For the bar charts what you see on the x-axis is the categories. Above each category is a separate column for each category.
Thanks!
Don
PieCharts with DefaultCategoryDataSet
Re: PieCharts with DefaultCategoryDataSet
Hi Don,
I think you have a good point. I've used the term 'category' in slightly different ways for the PieDataset and the CategoryDataset, so that is the source of the problem.
I've changed the CategoryDataset interface in CVS to make it more like a table (actually I've called it TableDataset). This does away with the difference between series and categories (replacing them with row keys and column keys), and should make it simpler to transpose a dataset (and also to display it in a JTable, but that is another issue). I'm still working on this, so I will endeavour to make the multi-pie chart work the way you have suggested.
Regards,
DG
I think you have a good point. I've used the term 'category' in slightly different ways for the PieDataset and the CategoryDataset, so that is the source of the problem.
I've changed the CategoryDataset interface in CVS to make it more like a table (actually I've called it TableDataset). This does away with the difference between series and categories (replacing them with row keys and column keys), and should make it simpler to transpose a dataset (and also to display it in a JTable, but that is another issue). I'm still working on this, so I will endeavour to make the multi-pie chart work the way you have suggested.
Regards,
DG
Re: PieCharts with DefaultCategoryDataSet
Thanks David. Any idea when these changes will be done?
Re: PieCharts with DefaultCategoryDataSet
I was hoping to get the next release out this month, but I have some catching up to do with JFreeReport so I'll have to see how it goes.
Regards,
DG
Regards,
DG