|
Grouping the x-axis in the stacked bar chart |
Posted by sam on Mar-10-2011 15:26 |
|
Hi,
I need to group the x-axis with the week and corresponding month by using java
String[] labels = {1", "2","3","4","5","6","7","8","9" ............ "53"};
"1 to 4 " as Jan -11
"4 to 8" as Feb - 11
.
.
.
"48 to 53" as -Dec-11
Ref attachment..
Please help..
|
Re: Grouping the x-axis in the stacked bar chart |
Posted by Peter Kwan on Mar-10-2011 23:12 |
|
Hi Sam,
You may consider to use an axis label table with 2 rows - one of the week number, and one for the month.
You may refer to the "Data Table (1)" sample code (you may look for "Data Table (1)" from the ChartDirector documentation index) for an axis label table with multiple rows. In that sample code, all rows have the same number of cells. But for your case, you can create a row in each a cell span multiple columns (eg. the "Jan" cell would span columns 0 to 3). The API to do this is CDMLTable.setCell (you may look for "CDMLTable.setCell" from the ChartDirector documentation index).
Hope this can help.
Regards
Peter Kwan |
|