Axis 2 « Axis « JFreeChart Q&A





1. How to implement Linear-Logarithmic axis (split axis)?    jfree.org

I was wondering what would be the easiest way to implement a linear-logarithmic domain axis in JFreeChart, to the best my knowledge this hasn't been done yet. I don't mean one linear and a second logarithmic axis but I mean a combination of the two, for instance the first part linear and starting a certain value the rest of the axis ...

3. Change label on axis    jfree.org

4. Period Axis Label Generator    jfree.org

5. domin axis label position    jfree.org

Hi I have chart in which the domain axis values are dislayed as January Feburary March ............. ............. December Now these values are overlapped on the chart domain axis.I want to display these values as January March May ........... in one row Feburary April June in another row. I am using the XYPlot Chart. Any pointers are highly appreciated. Secondly, I ...

6. segmented value axis    jfree.org

Hi there, I hava another unsolved problem. Several time series should be displayed in one chart. But if there is one time series with significantly larger values than the others, the chart does not look very good. For example, if there are two time series. The first has values between 0 and 10, and the other between 90 and 100. Then ...

7. Draw in axis region    jfree.org

8. Code for multiline Axis label / text    jfree.org

Code for multiline Axis label / text by tomkieffer Wed Jan 16, 2008 2:05 pm Hi, to generate multiline axis labels I changed the following two methods (getTextBounds, drawRotatedString) in org.jfree.text.TextUtilities as it seemed more comfortable to me than trying to change the axis class to use textblocks (although this was a lot of work, too, despite the small result). ...





10. Need help with setting axis steps?!    jfree.org

Need help with setting axis steps?! by DerStefan Mon Jan 28, 2008 3:31 pm Hi - Just i few days ago i bought the JFreeChart manual, to find a solution for my problem. But anyway i can't resolve it. Perhaps anyone of you is able to help me in any way My problem: I created an areaChart with a lot ...

11. How can I set the first shown value of the Axis (TickMark)    jfree.org

That's strange, setRange worked perfectly for me... maybe set the beginning range to 19 and see if the 20 showed up? We had a clipping problem at the top of our range, so I just added 5 to the top of the range and anyone who scored 100% will now show the full box.

12. how to get axis bounds    jfree.org

13. Axis Label Rotation Dilemma    jfree.org

I have read in a few posts on this forum that when axis labels are rotated, the alignment is off a bit, and becomes more pronounced the larger the dataset is. We also have this logged as an issue for our project ( http://jira.pentaho.org/browse/BISERVER-946 ) . The problem with the resolutions I have tried to use is that they are specific ...

15. Max and min value of an axis    jfree.org

16. PiePlot axis capabilities    jfree.org





17. Number Axis    jfree.org

Several weeks ago, I have prepared patches for XYPlot, ValueAxis, NumberAxis, DateAxis and DateTick to allow the following: DateTick has a constructor that accepts a TickType property. ValueAxis has a minorTickCount property with a public getter/setter. NumberAxis/DateAxis will create minorTicks based on the minorTickCount in their refreshTicksXXX methods. XYPlot has a minor grid for the domain and/or range axis that can ...

18. Number Axis 2    jfree.org

19. Trailing Zeros in Axis    jfree.org

Is there a property to set or a way to customize an axis such that it doesn't display trailing zeros? I'm using an XYPlot with a DateAxis for the domain (x) axis and a NumberAxis for the range (y) axis and auto scaling is turned on for the y axis. What I'm getting for the tick labels with one particular data ...

20. BUG: Hide Axis Label axis.setLabel(null) render issue.    jfree.org

I set the Axis Label to null to hide the label text, since can't find any other method for this. As a side effect, the rendering gets messed up. Seems to add a load of whitespace where the label used to be, and also doesn't give enough spacing between multiple axes. See image attached. Likewise, if I start a plot without ...

21. 10.000 pixel long image need's an Axis    jfree.org

Hi, I try to use JFreeChart a little out of its original design - maybe someone has tried this. (By the way Thanx to this fantastic package !) I have an image which is 512x10000 in dimension. I would like to have a NumberAxis drawn next to it. All looks perfect as long as I stick to small window sizes like ...

22. how to hide axis label    jfree.org

23. Fixed physical value axis length    jfree.org

Hi, I'm using JFreeChart in the JasperReport environment and have not been able to solve the following problem: I'm making simple barcharts some of which has legends, some of which have x-axis labels stretching over many lines. So, if I keep the size of the plot constant in Jasper, the actual plot size on paper will vary from chart to chart. ...

24. Value Axis gaps    jfree.org

First I apologize because my english is not well, I'll try to explain my problem with simple phrases. I need a chart in a report. I desinged the report with iReports and now I'm trying to customize it. The chart is a multiple-axis chart with a bar chart an a line chart. I customize de chart to the same value axis ...

25. Change the color of the zero axis    jfree.org

26. time series chart, change the yy axis. doubles to strings    jfree.org

hello. I read the API and have not found anything to change the axis yy where are the double by String. someone helps me. thank you. see the image for example time chart. Code: Select all | String 1 -| ...

28. Custom axis label (CONTINUED)    jfree.org

by ugh_bough Mon Jun 09, 2008 1:59 pm what i did is this: extend NumberAxis and override drawLabel() Code: Select all /** * A NumberAxis that draws HTML-Text as its label. */ private static class MathNumberAxis extends NumberAxis { ...

29. MultiLine Axis Labels    jfree.org

Hi, I need to have a multiline label for my value axis. More precisely, my value axis has a label of "Y >>BETTER>>" while i need it to be Y >>BETTER>>. Hope you get what i say. I have tried numerous things like inserting a break/newline character and even concatenating 2 strings. But i do not seem to find a fix ...

30. axis.setRangeType(RangeType.POSITIVE);    jfree.org

Hello, i use the following class as a customizer class with JasperReports. It works fine. I have one question. After i use axis.setRangeType(RangeType.POSITIVE) i have also to set some Color for one or more Series. Without this the axis.setRangeType(RangeType.POSITIVE) has no effekt. If there an other way to use axis.setRangeType without a additional renderer call? Regards, Henry Code: Select all package ...

31. Management data axis    jfree.org

Good morning, I want to run the numbers that is on my axis. I hope there is cellement whole number of 1,2,3 and not 1,1.5,2,2.5,3. I can not find how to do that. I think it lies on the side of NumberAxis. I try to do that, but it does not work: NumberAxis axeO = (NumberAxis) xyplot.getRangeAxis ();// recovery of the ...

32. values on each axis in spiderweb    jfree.org

34. why can not show the canlendar in the Abscissa axis    jfree.org

why can not show the canlendar in the Abscissa axis for example 1- is Wrong Format public void doGet(HttpServletRequest request, HttpServletResponse response) throws IOException, ServletException{ OutputStream out = response.getOutputStream(); try { TimeSeries s2 = new TimeSeries("Data2", Day.class); s2.add(new Day(1,9,2008), 129.6); s2.add(new Day(2,9,2008), 123.2); s2.add(new Day(3,9,2008), 117.2); s2.add(new Day(4,9,2008), 124.1); s2.add(new Day(5,9,2008), 122.6); s2.add(new Day(6,9,2008), 119.2); s2.add(new Day(7,9,2008), 116.5); s2.add(new Day(8,9,2008), 112.7); ...

36. How to make an orthonormal axis ?    jfree.org

37. how can i customize the axis labels    jfree.org

by aryanarvind Thu Feb 19, 2009 10:08 pm Hi, You might want to check the following code and try to change the pattern to suite your requirement. right now I am using new DecimalFormat("0") try changing this to new DecimalFormat("0%") I am not sure if this works. You can use this custom class to your ValueAxis. Code: Select all ((NumberAxis) ...

38. Axis visibility of bubble chart other than (0,0)    jfree.org

Hi all, I have to make the visibility of my Axis to intersect other than at (0,0) co-ordinates. Fot (0,0) intersection we have setRangeZeroBaselineVisible(true) and similarly for domain. But the problem that i have is my range on X-axis starts form say (1,25) and y axis say(50,100) then the intersection of the lines should happen at (12.5) which is the center ...

39. Axis in Bubble Chart    jfree.org

Hi, Can anybody tell me if I can have the axis in my bubble chart at any value otherthan 0 or the 4 edges of my graph. I need to create a chart(bubble) where my axis (both domain and range) are at the center of the graph while the extremes of the two axis may not be symmetric about 0. Ex: ...

40. Currency in Axis Items    jfree.org

Hi all I'm using the BarRenderer3D class to draw a chart, with the bars aligned horizontally rather than vertically. I was wondering is there a way to change the text of the valueaxis so that instead of displaying numbers like 10,000, 20,000, 30,000 etc I could prefix those numbers with a euro sign as the chart is showing financial figures. Any ...

41. Question regarding customizing axis    jfree.org

Hello, first of all - I am using the orson package with netbeans. I want to make my scatterplot axis be a static range instead of auto but I can't seem to find a way to do it! I am comparing a lot of different scatter plots and it is not nice to have differently ranged axis on all of them ...

42. Catagorry axis lables gets truncated    jfree.org

Hello, I am using JfreeChart 1.0 and java 1.5. I am creating a horizontal bar chart. When i give a long lable for catagory axis it gets tuncated. Is there any method by which i can write lables in multiple lines or i can increase no of characters displayed in chart? i tried to use categoryAxis.setMaximumCategoryLabelWidthRatio(0.5f); it is not solving my ...

43. ask one,about Axis.....3Q    jfree.org

by david.gilbert Tue Jan 20, 2009 9:50 am Here is a demo that I meant to add to the collection that is included with the JFreeChart Developer Guide. It implements the minor tick marks, which is I think what you are asking for: Code: Select all /* ------------------------ * MinorTickMarksDemo1.java * ------------------------ * (C) Copyright 2009, by Object Refinery Limited. ...

44. axis label alignment    jfree.org

45. first axis wont start at 0 when autorange    jfree.org

Hi there, i got a dynamic Chart with 2 Axis. I just want the first Axis to get mapped to the dataset. Works fine, but the Axis only has one value. Looks terrible! I want the axis to start at 0. Tried to do the Axis as an NumberAxis but then the AutoRange doenst work. Any ideas? Code: Select all ...

46. Highlight a data on the data axis on selection    jfree.org

Hi All, Could some one let me know if there is a way to highlight the Date in the Date-Axis? This is for selection of the date in the BarChart. The highlight could be anything that signifies that the date was selected. Underlining the date or adding border to the Date label etc.

47. Can I create a tool tip for Axis label?    jfree.org

Hi, I read through the JFreeChart documents and couldn't find a way to generate a tool tip for the Axis label. In my case, I have a bar chart whose Y axis (NumberAxis) label is very long and the chart truncates the label. I want to display a tool tip on top of the Y axis label to show the full ...

48. No axis labels when axis data value is tiny    jfree.org

I have some data which contains small values (i.e. 0.000000002345, 0.000000003355, etc). When I create a XYplot allowing it to create the standard default tick marks, it puts one mark at 0.0000000 and that it is. I need more resolution. I tried to change the formatter to display in engineering format. But all that does is display the one tick label ...

49. axis label    jfree.org

Hello, I made a combined range XYPlot. Everything thing looks fine except that the last x-axis label for subplot1 overlaps with the 1st x-axis label for subplot2. Is it possible for me to get rid off one label? Or is there a way to put extra spaces between the two subplots so that the labels won't overlap? Thanks in advance. Jane ...

50. Adding a gap to an axis.    jfree.org

Hi guys, I have a problem with the display of my Time Series pLot. I want to update the plot way before the right edge of the ChartPanel. In MemoryUsageDemo for example, you can see that the plot is getting updated at the right edge of the panel. Is there any way to add a gap or something between the plot ...

51. how to change axis labels width    jfree.org

54. How to set (only) label interval of axis ranges    jfree.org

I have set the the date to a customizable unit... domainAxis.setAutoRange(false); domainAxis.setTickUnit(new DateTickUnit (DateTickUnitType.MINUTE, unitInterval)); domainAxis.setMaximumDate(new Date(30000 * groupOption * (2880 / unitInterval))); However I want the range (value), label below axis not show for every unit because if the interval is short it will become unreadable because the labels are to close apart... Is it possible to determine when it ...

55. Logarithm Axis goes linear below 1    jfree.org

I have noticed that a Logarithm Axis goes linear when a value less than 1 is encountered. This would appear to be a bug. Suppose you have the values 100, 10, 1 0.1 and 0.01. These values should be separated equally on a base-10 logarithmic scale. However, with the current release of jfreechart, the 100, 10 and 1 values are equally ...

56. Show axis, but hide data    jfree.org

I have a requirement to show a multiple axis chart - one axis would be bars representing CFM (for compressed air), and the other showing CFM * X dollars. I would like to actually only show the bars for one of the series though so I don't have overlapping bars (which I have now). I have tried renderer.setSeriesVisible(false), renderer.setSeriesVisible(datasetNum, false) - ...

57. Change position of Axis Label    jfree.org

58. Repeated numbers on axis    jfree.org

59. some help with symbol axis    jfree.org

JFreeChart chart = ChartFactory.createXYLineChart("Melting Point","Base position","Melting point",data,PlotOrientation.VERTICAL,true,true, false); final XYPlot plot = (XYPlot) chart.getPlot(); final NumberAxis axis = (NumberAxis) plot.getRangeAxis(); axis.setAutoRangeIncludesZero(false); final NumberAxis xaxis=(NumberAxis)plot.getDomainAxis(); ...

60. chart axis changes on resize    jfree.org

hi i have jfreechart rendering a simple line chart on the screen quite nicely. i then regenerate that exact chart and scale it up (for printing) using techniques similar to those described here: http://www.jroller.com/dgilbert/entry/creating_thumbnails_with_jfreechart the chart generates fine and looks good on paper, however the domain axis scale has changed dramatically after the resize. it would appear that chart.draw(graphics2d, rectangle) tinkers ...

61. Make axis meet    jfree.org

I am using DefaultCategoryDataset to plot a line graph, with months on the x-axis (domain) and counts on y-axis(range). But there is some space/gap before the first item on domain axis. How can I make it touch the range axis? First item needs to plotted directly on the range axis without any gap. Hope I am able to convey my problem ...

62. HTML marking inside axis label    jfree.org

Hello. I'm creating chart with ChartFactory.createTimeSeriesChart method, and my domain axis label should contain a huge fraction expression. My idea is to use html marking (underline tag ) to make this fraction expression "look pretty". It works with JLabel perfectly. But not working if I supply this as a parameter to the mentioned method. I.e. html marking is not interpreted, just ...

63. Hide or change axis on labels?    jfree.org

64. java2DToValue inaccurate on inverted axis!    jfree.org

java2DToValue inaccurate on inverted axis! by mjs483 Fri Sep 18, 2009 9:43 pm Hi, I'm playing around with JFreeChart v1.0.13 trying to see if I could possibly use NumberAxis as the axis of something other than a JFreeChart. I've setup a simple example and I'm noticing that when the I invert the axis with setInverted(true) the values I get from ...

65. get axis min/max/major/minor    jfree.org

67. Word-wrapping (?) axis labels on an XY Plot    jfree.org

I've just inherited a JFreeChart 1.0.13-powered project so I apologize if I'm describing the issue poorly. (We own the 1.0.4 Developer Guide so we're tad out of date as far as documentation goes.) We have a TimeSeriesChart populated with a single TimeSeries (in a TimeSeriesCollection). We would like to format the time axis labels as such: MON 'YY Using a DateFormat ...

68. Number Axis Label wrapping    jfree.org

70. Transformed Axis labels    jfree.org

Axis labels are transformed in two ways: - The labels get strechded (e.g. vertical label gets stretched itself vertically when the chart with is a lot more than its heicht) - The font size of the tick labels is transformed. Specifying e.g. font size 12 i get a very small font if the chart is very small. the first thing is ...

71. How to set Custom values on Axis    jfree.org

72. Urgent pls help Query regarding Period Axis    jfree.org

Hi, I am using period axis i need set some Fixed time periods for the day like Early AM --12.00 am to 6.00 am Morning --6.00 am to 12.00 pm Afternoon --12.00 pm to 6.00 pm Evening --6.00 pm to 12.00 am Any help in this regard would be very much appreciated.... Thanks Sai

73. Reg Period Axis Labels    jfree.org

74. create gaps in axis    jfree.org

75. Problems with Axis and ItemLabels    jfree.org

Paint tickMarkPaint = new Color(0x00,0x00,0xff); Paint axisLinePaint = new Color(0x00,0x00, 0xff); Font tickLabelFont = new Font(NumberAxis.DEFAULT_TICK_LABEL_FONT.getName(), Font.BOLD, 12); Font labelFont = new Font("Eras Medium ITC", 0, 16); Stroke axisLineStroke = new BasicStroke(1.8f, BasicStroke.CAP_ROUND, BasicStroke.JOIN_MITER); Stroke tickMarkLineStroke = new BasicStroke(1.4f, BasicStroke.CAP_SQUARE, BasicStroke.JOIN_MITER); float tickMarkInsideLength = 2.8f; float tickMarkOutsideLength = 2.8f; ...

76. TimeSeriesChart with percentage value axis Problem    jfree.org

Hi I'm trying to create a TimerSeriesChart with a percentage values on the Y axis, but the Y axis label displays a bigger value that the ones that are shown on the chart ,e.g. the chart displays 35(also the tooltip) but in the Y axis label display 3000, how this can be fixed? I'm using a XYPlot and the Y axis ...

77. tool tips on axis labels    jfree.org

Hi guys, I'm trying to put tool tips on my axis labels. I've seen this post: viewtopic.php?f=3&t=27411 I see in JFreeChart::draw(), it rebuilds the EntitiesCollection, and calls this.plot.draw(...). In my case, I'm dealing with an XYPlot that has NumberAxis objects as its axes. In the post referred to above, it says I need to create an entity for my axes (I ...

78. Additional marks on axis    jfree.org

Hello everybody, I tried to find something about this, but failed, so any help would be helpful. I wish to add additional information to axis. As example, you can imagine horizontal line, as classical Marker that indicates the maximal available value in dataset, and I wish to see it's value on axis, above standart tick units. Something like this: So, the ...

79. Markers on the axis (or their equivalent)    jfree.org

Hello again! I'm trying to create this bubble chart. Now, I can display a bubble chart with the appropriate values, markers in the dataspace and so on. However, there is a requirement I am unable to satisfy so far. The X values are a score percentage. The requirement is that, below the values, a bar is displayed in the graph. This ...

80. Axis lost!    jfree.org

Hi, i had to display a dynamical chart picture in a web application. For this i want to use JFreeChart combined with primefaces. It works fine for this kind of datset: Code: Select all dataset.addValue(1, "paper_1", "Begriff_1"); dataset.addValue(5, "paper_2", "Begriff_1"); dataset.addValue(4, "paper_3", "Begriff_1"); ...

81. Help on XYAreaChart with markers on specific axis    jfree.org

XYSeries series = new XYSeries("Random Data"); series.add(0, 1); series.add(0, -1); series.add(1, 1); series.add(1, -1); series.add(2, 1); ...

82. HorizontalBarChart change axis position    jfree.org

Hello, It's my first time in this forum. I work with HorizontalBarChart and I would like customize my chart. I want: - In my chart, the axis is in the top but I want replace down. Is this possible? How? I'm looking for and I try with different options that I found but anything work it. - On the other hand, ...

83. get axis value on click    jfree.org

Re: get axis value on click by GOLAN Mon Feb 07, 2011 11:39 am Hi, my solution is: I am choosing series, so i have no problem with click on point that is under some other point (with same (x, y) position) - but it could be solved with out choosing series but with mouse wheel scrolling than grab point ...

86. changing axis label    jfree.org

Hi, I have a bar chart and i need to change the values of xy axis label. They come with "Values" and category by default i know i can change it because i can do it in properties of the graph in runtime, but i need to change it in development. What is the function to do that?

87. Constant plot-position when setting axis visibility?    jfree.org

Hello, I have a simple XYPlot in a ChartPanel with two range axis (one left and one right). For that plot, I let the user set the visibility for one of the range axis. However, when I hide a range axis, the plot will resize to use more space, of course. Is it possible to set a constant drawing "position" for ...

88. Axis Background    jfree.org

90. Item Labels get cut - UpperMargin without extending axis    jfree.org

I need to set upperMargin to properly display item label without extending the axis labels. Probability is displayed on range axis and it is confusing to show probability value 1.1 on on the axis. However I would like to display item label for value 1. Is there way to suppress displaying axis labels for values higher than e.g. 1?

91. Tooltips on axis values or labels    jfree.org

92. How to set and customize the axis origin?    jfree.org

hi all... It's possible to set an arbitrary value (i.e. 50) for the axis origin rather than 0 value? I need to display bars in a 3D bar chart with value less than 50 under the x axis and bars with value more than 50 over the x axis. (as if 50 is the origin of value axis). Thanks. Massimo

93. multi line axis labels    jfree.org

I'm assuming it wasn't implemented. What I am trying to do is have a multi line axis label with the time (hh:mm:ss) and the date on the second line (MM:dd:yy). I was trying \n as a string input into simpledateformat, but it didn't parse correctly. Any thoughts/suggestions on how to implement this? Thanks!

94. ReScaling of Log axis using JFreeChart    forums.oracle.com

Hi I'm using JFreeChart for creating logarithmic charts in my program.But when I'm zooming in some portion of the chart ,the tick mark level(numbers on Y axis) on Y Axis(which is of type LogarithmicAxis )disappears. For example when I'm zooming the portion between 10^2 and 10^3 ,I'm expecting this middle portion(On Y Axis) to be further subdivided logarithmically with new set ...