I'm working with JClass Bar charts. Each different data series has its own unique X Data Values that are not shared across all the other data series. Also, each data series is a different size. Some series contain only a few data points. Other series have many data points.
But not all of the expected bars are appearing on my chart. It is only displaying data for the first few points in each series. The number of data points included is equal to that of the series with the least number of points.
There is no way to make Bar charts handle uneven series sizes with the GENERAL data format.
Section 8.9 page 141 of the jcchart.pdf located in your <<JClass_HOME>>/docs/chart/pdf directory contains relevant discussion and a warning:
"There are two different types of Data Formats Array and General. Array-formatted data shares a single series of X-data among one or more series of Y-data. General-formatted data specifies a series of X- data for every series of Y-data. Array format is the recommended standard, because it works well with all of the chart types. General Format may not display data properly in Stacking Bar, Stacking Area, Pie Charts, and Bar Charts."
WORKAROUND
You can pad "dummy" extra datapoints in each series with HOLE values or Double.MAX_VALUE values (example code Bar.java attached) to increase the number of data points in each series to equal the series with the most DataPoints.
Applies to JClass 6.x.
© 2021 Quest Software Inc. ALL RIGHTS RESERVED. Feedback Terms of Use Privacy