Hi,
I build the data by code and I need to know if there's a word or something to represent the infinity, or should I assign inf as 0 in order to avoid exceptions. Is there anybody that could help me?
Thanks for all.
Infinity value in Value tag
-
- JFreeChart Project Leader
- Posts: 11734
- Joined: Fri Mar 14, 2003 10:29 am
- antibot: No, of course not.
- Contact:
Double.POSITIVE_INFINITY and Double.NEGATIVE_INFINITY are used in Java, but they will cause trouble if you put them in a dataset and try to plot them.
David Gilbert
JFreeChart Project Leader
Read my blog
Support JFree via the Github sponsorship program
JFreeChart Project Leader


-
- Posts: 844
- Joined: Fri Oct 13, 2006 9:29 pm
- Location: Sunnyvale, CA
Re: Infinity
A humorist's and purist's answer: plot nothing but one bar and leave off the range axis. In the truest sense of infinity, any finite data you have on the plot would be so small (infinitesimally small in fact) that even a painted atom would be too large to represent it in true scale.Morwen wrote:Has there been any change with a way to plot Infinity in JFreeChart?
Richard West
Design Engineer II
Advanced Micro Devices
Sunnyvale, CA
Design Engineer II
Advanced Micro Devices
Sunnyvale, CA
Well, considering you'll usually want to put infinite values with finite values, I'd expect it to appear as "infinity sign", and act the same way as 0 for positive (Above axis) and negative infinity to appear below axis, but the same as 0 in all other respects, and yet, would not affect other values (Since we DO want to see them, unlike what would happen when we scale it to size).
I do agree that we shouldn't have a value axis, since it has an infinite value.
In essence, I saw there was no real handling for what David mentioned above still in version 1.04.
Hope this helps a little,
Morwen.
I do agree that we shouldn't have a value axis, since it has an infinite value.
In essence, I saw there was no real handling for what David mentioned above still in version 1.04.
Hope this helps a little,
Morwen.
-
- JFreeChart Project Leader
- Posts: 11734
- Joined: Fri Mar 14, 2003 10:29 am
- antibot: No, of course not.
- Contact:
I agree, it would be a good thing to add handling for these values.Morwen wrote:Well, considering you'll usually want to put infinite values with finite values, I'd expect it to appear as "infinity sign", and act the same way as 0 for positive (Above axis) and negative infinity to appear below axis, but the same as 0 in all other respects, and yet, would not affect other values (Since we DO want to see them, unlike what would happen when we scale it to size).
David Gilbert
JFreeChart Project Leader
Read my blog
Support JFree via the Github sponsorship program
JFreeChart Project Leader

