0

I am creating spider chart using SpiderWebPlot of JfreeChart. Axis labels are not displaying in generated image of chart.

What should be done for displaying labels in image?

Here is my code :

SpiderWebPlot plot = new SpiderWebPlot(categoryDataSet);
            plot.setStartAngle(90);
            plot.setInteriorGap(0.30);
            plot.setWebFilled(true);
            plot.setBackgroundPaint(new Color (215, 215, 215));
            plot.setOutlineVisible(true);

Image generated from above plot is as below:

Generated Image of spider web chart

MasterAler
  • 1,614
  • 3
  • 23
  • 35
Jennifer
  • 107
  • 1
  • 1
  • 5
  • It looks like you crossed out the labels in your image; please clarify; more [here](http://stackoverflow.com/search?tab=votes&q=user%3a230513%20%5bjfreechart%5d%20SpiderWebPlot). – trashgod Mar 03 '17 at 11:59
  • @trashgod yeah labels are going off the image, can you tell if they can by put somehow in image only or width provided to the chart? I have already gone through above links. – Jennifer Mar 03 '17 at 12:55
  • I'd override `getPreferredSize()`, for [example](http://stackoverflow.com/a/10277372/230513). – trashgod Mar 03 '17 at 23:54
  • http://www.jfree.org/phpBB2/viewtopic.php?f=3&t=24530 it helped me to wrap labels on axis of this chart – Jennifer Mar 04 '17 at 06:23
  • You can [answer your own question](http://meta.stackoverflow.com/q/17463/163188), citing the forum thread. See also this related [example](http://stackoverflow.com/a/29808858/230513). – trashgod Mar 04 '17 at 09:15

1 Answers1

0

You can use:

plot.setInteriorGap(0.40);
MasterAler
  • 1,614
  • 3
  • 23
  • 35