A couple of possiblities:
Either implement your own Dataset wrapper that returns only the N latest points even when having more than N.
Or alternatively implement zooming and/or scrolling to your graph so that the view only shows the N latest but you can scroll back to view the older data.
Search found 51 matches
- Wed May 20, 2015 10:51 am
- Forum: JFreeChart
- Topic: Is it possible to have a chart only show the end of a series
- Replies: 1
- Views: 3820
- Fri Nov 28, 2014 1:07 pm
- Forum: JFreeChart
- Topic: Wrapping XYPlot Around Graph
- Replies: 2
- Views: 4352
Re: Wrapping XYPlot Around Graph
I don't fully understand what your X-axis is (some kind of time, perhaps?), but here is a suggestion: use just the one series: -add value (x1, 5) -add value (x2, 0) -add value(x2, null) -add value(x2, 360) -add value(x3, 355) So you would compute the change from 0 to 360 before adding the data to th...
- Thu Sep 05, 2013 1:45 pm
- Forum: JFreeChart
- Topic: How can I fix a line chart with disconnected points
- Replies: 2
- Views: 4396
Re: How can I fix a line chart with disconnected points
If you change your chart from CategoryChart to XYChart then you would get connected lines.
I am not familiar with CategoryChart so I do now know if it is also possible with that.
I am not familiar with CategoryChart so I do now know if it is also possible with that.
- Fri Apr 05, 2013 8:47 am
- Forum: JFreeChart
- Topic: Raising tooltips when mouse is not exactly over the entity
- Replies: 3
- Views: 8880
Re: Raising tooltips when mouse is not exactly over the enti
You might want to take a look at TooltipChartPanel which has basic framework for generating the tooltips on-the-fly when needed (instead of creating all tooltip entities before rendering). It had also a parameter for defining the hotspot radius. See http://www.jfree.org/phpBB2/viewtopic.php?p=69588#...
- Mon Dec 17, 2012 11:43 am
- Forum: JFreeChart
- Topic: Display a TimeSeries in one call
- Replies: 3
- Views: 6168
Re: Display a TimeSeries in one call
You should probably call JFreeChart.setNotify(false) before your loop, add the new items directly to the existing dataset, and then after the loop call JFreeChart. setNotify(true) . Now each new element forces a redraw of the whole chart (with the increasingly big dataset) via notifications. By disa...
- Tue Oct 09, 2012 11:32 am
- Forum: JFreeChart
- Topic: XYPlot Line Connecting
- Replies: 2
- Views: 4366
Re: XYPlot Line Connecting
Adding a null value causes a gap in the line.
...
xy1.add(30, 64);
xy1.add(40,null);
xy1.add(70, 80);
...
...
xy1.add(30, 64);
xy1.add(40,null);
xy1.add(70, 80);
...
- Mon Dec 05, 2011 11:49 am
- Forum: JFreeChart
- Topic: disable negatives values on lineChart with zoom
- Replies: 5
- Views: 11219
Re: disable negatives values on lineChart with zoom
If you are going to show only positive Y-values why not use the NumberAxis method
for your Y-axis? This way the zoom out will not slip into negative range.
Code: Select all
setRangeType(RangeType.POSITIVE)
- Tue May 31, 2011 8:13 am
- Forum: JFreeChart
- Topic: How to get data points display on mouseover
- Replies: 1
- Views: 3171
Re: How to get data points display on mouseover
It is possible, you need to generate the image map for the image with the API.
Unfortunately I am not familiar with that API and cannot help you further but I am certain that if you search the forum you can find the answer.
Unfortunately I am not familiar with that API and cannot help you further but I am certain that if you search the forum you can find the answer.
- Thu Apr 21, 2011 2:11 pm
- Forum: JFreeChart
- Topic: Porblem with month in Jfreechart
- Replies: 4
- Views: 6103
Re: Porblem with month in Jfreechart
What are you trying to achieve? Now you have summarized the database values into one datapoint per month. I am guessing that you have only date values for March and April in the database - hence the two datapoints in the graph. Apparently this is not what you wanted, so please either re-think your l...
- Thu Apr 14, 2011 11:42 am
- Forum: JFreeChart
- Topic: Probleme with jfreechart
- Replies: 2
- Views: 3863
Re: Probleme with jfreechart
You are adding the series twice into the dataset.
First in the constructor:
and immediately again:
Remove the second entry and you should be fine.
First in the constructor:
Code: Select all
final TimeSeriesCollection dataset = new TimeSeriesCollection(series);
Code: Select all
dataset.addSeries(series);
- Fri Oct 01, 2010 6:50 am
- Forum: JFreeChart
- Topic: Overlayed chart with 2 bar
- Replies: 6
- Views: 7099
Re: Overlayed chart with 2 bar
Perhaps ClusteredXYBarRenderer is what you need:
http://www.jfree.org/jfreechart/api/jav ... derer.html
http://www.jfree.org/jfreechart/api/jav ... derer.html
- Mon Jun 21, 2010 11:38 am
- Forum: JFreeChart
- Topic: setDrawSeriesLineAsPath(true) causes lines to disappear
- Replies: 2
- Views: 4684
Re: setDrawSeriesLineAsPath(true) causes lines to disappear
Which version of JFreeChart are you using? There was a problem in the initial versions where this happened but it should be fixed now.
I cannot remember on the top of my head the broken version nor where it started to work. You should be able to find similar threads with the Search, though...
I cannot remember on the top of my head the broken version nor where it started to work. You should be able to find similar threads with the Search, though...
- Thu Jun 03, 2010 5:25 am
- Forum: JFreeChart
- Topic: ChartMouseListener : Please help me !!!!!!
- Replies: 3
- Views: 6528
Re: ChartMouseListener : Please help me !!!!!!
You don't have to have entity collection. Please take a look at the TooltipChartPanel by RoyW , it has basic framework for generating the tooltips on-the-fly when needed. It maps the mouse coordinates to X,Y index and scans the datasets for matching datapoints. See http://www.jfree.org/phpBB2/viewto...
- Thu Nov 19, 2009 10:13 am
- Forum: JFreeChart
- Topic: Zoom doesn't display lines if no points inside zoom area
- Replies: 4
- Views: 8220
Re: Zoom doesn't display lines if no points inside zoom area
Could it be that your JFreeChart is version 1.0.10 or older?
See http://www.jfree.org/phpBB2/viewtopic.p ... 510#p73510
If the answer is yes, either update your JFreeChart libraries or alternatively do this
See http://www.jfree.org/phpBB2/viewtopic.p ... 510#p73510
If the answer is yes, either update your JFreeChart libraries or alternatively do this
Code: Select all
renderer.setDrawSeriesLineAsPath(false);
- Tue Oct 27, 2009 7:46 am
- Forum: JFreeChart
- Topic: Disconnected Chart
- Replies: 1
- Views: 3804
Re: Disconnected Chart
If you were to use XYLine chart (and of course XYSeries for the data), then the lines would have no gaps.
Mind here that I have absolutely no knowledge of Category charts nor Jasper reports, so maybe someone has a solution for a Category chart.
Mind here that I have absolutely no knowledge of Category charts nor Jasper reports, so maybe someone has a solution for a Category chart.