Re: Possible bug in SelectRangeWidget ...

Hi Don,

I have put a potential fix for this bug online at:
   http://skyking.microscopy.wisc.edu/curtis/Convert.java
   http://skyking.microscopy.wisc.edu/curtis/RangeSlider.java
   http://skyking.microscopy.wisc.edu/curtis/RangeWidget.java

Convert and RangeSlider are part of visad/browser, and RangeWidget is part of visad/util.

The new versions of these classes err on the side of caution when rounding (i.e., the larger value is rounded up, while the lower value is rounded down), to ensure that no data points are "rounded out" of the selected range.

Please let us know if this solves your problem.

Thanks,
-Curtis

Flaggs, Don wrote:

Bill,

The below approach appears to be working nicely.  The bad news is that
it appears to have maybe uncovered a "bug" in VisAD's brushing widgets
in that valid points appear to be "eliminated" because of truncating
display values at the upper end?!?  Attached is a screen dump showing
what's happening to the "f1" parameter in the data set currently being
displayed prior to any brushing operations.  f1's max is 6040.451843
while the widget is showing a max value of 6040.451, which apparently
causes that data row to be dropped from the display.  In the lower
left-hand-corner of the screen dump, you can see that the
rangeSelect[0].length is 1303, which is the correct number of rows in
the dataset, while the remainingPts is 1302, found by cycling through
the rangeSelect[][] array looking for false value.  Since no brushing
has occured, both should show 1303.  The row found to be "false" is the
row containing the f1 max of 6040.451843, which is consistent with the
above assertions.  Truncation at the lower bounds is not a problem.

thanks...  dlf