category « Axis « JFreeChart Q&A





1. Category Axis and Date Axis on the same Plot in jFreeChart?    stackoverflow.com

I am trying to plot a graph having two subplots. In the first subplot, I have a line and scatter graph. In the second subplot I have a bar plot. I ...

2. Stretching out category axis labels    jfree.org

I'm stumped on how I can stretch out the display of category axis labels. I'm using JFreeChart 1.0.0 RC1. Here's the chart: Here's the snippet of code where I manipulate my category axis: Code: Select all CategoryAxis categoryAxis = new CategoryAxis( y1Label ); categoryAxis.setMaximumCategoryLabelLines( 1 ); ...

3. invert category axis    jfree.org

4. fixed category axis - how to?    jfree.org

Hi all, I have a line chart which has areas with no data, so when there's no data I want the chart to display nothing (no line), but I want it to display the category label. Somthing like this: --------------- Jan Feb Mar Apr If there's no data for Apr just don't display the data but display the category label. Thank ...

5. Changing Range Axis Labels - Scatter and/or Category    jfree.org

Changing Range Axis Labels - Scatter and/or Category by mriehl Thu Sep 08, 2005 1:45 pm All - Trying to develop a plot that shows the following and I'm having a hard time. I've got data that looks like this: (x, y color indicator) 1, 101, yellow ... 50, 101, red ... 100, 101, green ... Then, I've got the ...

7. date axis to category plot    jfree.org

9. Extended Category axis example    jfree.org





10. staggered category axis labels    jfree.org

11. Better Label support for Category Axis    jfree.org

Is there a way currently in JFree where I can render my labels like the chart I provided. I want to be able to add two dimensions to my row axis, and based on the order that I add them, I want the labels to be displayed as a hierarchy. In this example Product Category was added first, then Region, so ...

12. Sub category axis with a difference    jfree.org

My requirement for sub category axis is somewhat different wherein the category items should be grouped under a parent category item. I basically wanted my sub category items different for categories and thus could not use the sub category axis. Would someone like to throw light on my current problem?? Thanks in advance

13. Category Axis    jfree.org

Hi, I can't turn the category axis off or change its color to white. Here's what I have tried already. CategoryAxis domainAxis = (CategoryAxis) plot.getDomainAxis(); domainAxis.setAxisLineVisible(false); domainAxis.setVisible(false); domainAxis.setAxisLinePaint(Color.White); The above calls work for the range axis and I can turn it off, but a light gray category axis just won't go away. The chart is a bar chart and orientation is ...

14. Alignment of Category Axis    jfree.org

Hi, I've searched through postings, but could not find this issue addressed. I am sure it impacts many charts. I have a simple bar chart with four bars that works great when at least one of the four bars has a non zero value. When all four bars are zero, the vertical alignment of the category axis changes. It appears that ...

15. Omitting tick labels in category axis    jfree.org

Hi, I have a Category Axis with a lot of categories. The tick labels in the axis are drawn over each other, thus they are not readable anymore. As there's a system in the category captions, leaving out some of them would be perfect. Is there a way to auto-trim the axis? Or can anybody give me a hint where to ...

16. Range in categories (X axis)    jfree.org

Hi! On the categories of my line chart I have dates. What I want is to display them with an interval of 1 month, I mean if I have a point on 05/11/06 and also another one in 26/02/07, I want the X axis to look like: 01/11/06 01/12/06 01/01/07 01/02/07 01/03/07 And of course the points drawed where they belong. ...





17. Override the tick label on a category axis    jfree.org

Hi, Is it possible on a category axis to override the tick label so that it is not just the name of the category. I have the following data: 1 27 A 2 34 B 3 57 C 4 12 A 5 82 B 6 32 C I would like to see 6 ticks on the domain axis in the order ...

18. Problem with Combined Domain Category Plot Range Axis'    jfree.org

Problem with Combined Domain Category Plot Range Axis' by rpratt Wed May 30, 2007 3:03 pm I have searched the forums for any issues related to this but can not find any related posts. I am using the dev guide for 1.0.0-pre1 and can not find my sample code for the charts to see what I am doing wrong. I ...

19. Category Axis    jfree.org

Hey all. First time visiting these forums, so first post ever. I had a problem where I was making a histogram that had ~100 bars, and the category I used was the range the bar on the histogram took up. So I had a while bunch of bars that had "categories" that were like "101-200", "201-301", etc. Since there were so ...

21. Need to do grouping on category Domain Axis....    jfree.org

Hi, Is it possible to do grouping based on columns on category domain axis? Only possible option I have seen for this is 'GroupedStackedBarRenderer'. But then this will only work with stacked bar charts. I need grouping on most of the chart types. eg. line charts, bar charts etc. eg. If I have bar chart with bars as month of the ...

23. Change Category Axis Label At Runtime    jfree.org

Hi I have the following series 1 3.30 2 6.84 3 9.27 4 10.29 5 13.05 6 15.06 7 18.01 8 19.89 9 23.59 10 26.15 11 28.95 12 30.68 Numbers 1,2,3......12 are displayed on the X-Axis. Numbers 3.30,6.84.......30.68 are displayed on the Y-Axis. I am using the Linechart. My question is while displaying the chart i want to replace the ...

28. Category Axis label positioning    jfree.org

I wrote a renderer which will take the values of a category and will draw diagram in a single line.The label for this category generally appears in the middle of the series, how can I place it near to the diagram drawn. How can I decrease the width between the categories. -Shiva.S

30. 2 set of values in Category Axis    jfree.org

Hi, I have a 2 set of values in Category axis, but same value in Number Axis: Eg: Number axis values : [ 10, 9, 8, 6, 3, 5, 7, 9, 11] Possible Category Axis value: ColumnKeys1 = [ S1, S2, S3, S4, S5, S6, S7, S8, S9] or ColumnKeys2 = [91, 92, 93, 94, 95, 96, 97, 98, 99 ] ...

32. How to set category axis for dual axis    jfree.org

How to set category axis for dual axis by vsai1986 Tue Feb 23, 2010 8:07 am Hi I am preparing a dual axis chart my req is on left axis of the chart i need to have values and on bottom axis also some numbers but on right axis i need some categorys to be displayed... i am attaching the ...

34. Customize Category X-axis label !!!    jfree.org

Is it possible to customize Category Axis to display text at the bottom of the bars in (Bar Chart) ? I want to display text at the bottom of the bars ( i.e. in space between bottom of the bar and X-Axis ) Any help is appreciated BTW: Can I attach files to this forum. I have a screen shot of ...

36. how to set dateaxis in category axis of category plot    jfree.org

JFreeChart jfreechart = ChartFactory.createLineChart("", "Interval", displayUnits, dataset, PlotOrientation.VERTICAL, false, true, false); CategoryPlot categoryplot = (CategoryPlot)jfreechart.getPlot(); categoryplot.setBackgroundPaint(Color.white); CategoryItemRenderer lineandshaperenderer = new LineAndShapeRenderer(); ((LineAndShapeRenderer) lineandshaperenderer).setDrawOutlines(true); ((LineAndShapeRenderer) lineandshaperenderer).setShapesVisible(false); categoryplot.setRenderer(lineandshaperenderer); CategoryAxis domainaxis= ((CategoryPlot) categoryplot).getDomainAxis(); domainaxis.setCategoryLabelPositions(CategoryLabelPositions.UP_45); domainaxis.setLowerMargin(0.01); domainaxis.setUpperMargin(0.01); domainaxis.setMaximumCategoryLabelWidthRatio(10.0f); ValueAxis rangeAxis = new NumberAxis(displayUnits); rangeAxis.setVisible(true); rangeAxis.setStandardTickUnits(NumberAxis.createIntegerTickUnits()); rangeAxis.setAutoRange(true); categoryplot = new CategoryPlot(dataset, domainaxis, rangeAxis, lineandshaperenderer); JFreeChart chart = new JFreeChart("", JFreeChart.DEFAULT_TITLE_FONT, categoryplot, false); return chart;

37. Category Axis: Label overlap question and summary    jfree.org

I wanted to summarize my understanding of the problem from previous posts, make a suggestion with examples, and confirm that understanding. So, currently, if you have too many category labels given the size of the chart, those labels will overlap. Your only options is to switch the label orientation to vertical (for a horizontal axis) and prevent wrapping, as follows: [CategoryAxis].setCategoryLabelPositions(CategoryLabelPositions.UP_90); ...