marcomachadosantos / gwt-chronoscope

Automatically exported from code.google.com/p/gwt-chronoscope
GNU Lesser General Public License v2.1
0 stars 0 forks source link

Chart can't deal with 0 datasets or a dataset having 0 points #99

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
Currently, the Chronoscope chart must be constructed with at least 1 dataset 
having 0 points.  
This proves to be a cumbersome usage constraint in cases where data needs to be 
added/removed dynamically.

Some examples of where this becomes and issue:

Case 1: realtime monitoring.  When the monitoring chart is first created, no 
data points will exist 
until the first value is received from the system being monitored.  So in this 
case, we would want 
to construct an empty dataset and append points to it as they are received.

Case 2: Adding/removing datasets from the chart via the Timelord UI.  Users 
will be able 
add/remove datasets to/from the chart.  The current framework does not permit 
the case where 
the chart contains only 1 dataset and the user wishes to remove that dataset 
(e.g. they want to 
replace dataset "Foo" with dataset "Bar").

One problem is what to render for the domain and range axes on a 
freshly-constructed XYPlot 
having no datasets, since without any data, the plot doesn't know what units to 
display.  A 
proposed solution is to display some generic ticks so that the chart still 
looks "chart-like" (vs. 
just a blank box, which would be disconcerting to many users).

Original issue reported on code.google.com by chadtaka...@gmail.com on 1 Dec 2008 at 9:12

GoogleCodeExporter commented 8 years ago
Correction in first sentence in previous comment: "having 0 points" should read 
"having at least 1 point".

Original comment by chadtaka...@gmail.com on 1 Dec 2008 at 9:18

GoogleCodeExporter commented 8 years ago
Came across this issue today but what I found was:

Dataset containing exactly 1 point with a value  -> browser hangs on an infinite
script loop causing a memory leak. Occurs in IE as well as FF. GWT console 
mentions
something like an ArrayIndexOutOfBoundsException while computing tick size, 
which
seems logical while having only one point in the domain.

Used chronoscope r844.

Original comment by j.bros...@gmail.com on 6 Aug 2009 at 11:21