When I was trying to look at some data that included float values ranging
from 0-1.0, I noticed I got into an infinite loop. Appears this happens when
the y-range value is exactly "1.0". The following snippet of code
helps explain this, and may be a bug...

in Exhibit.ScatterPlotView.prototype._reconstruct=function():

var V=F-Z;
551var M=H-g;
552var i=1;
553if(V>1){while(i*20<V){i*=10;
554}}else{while(i<V*20){i/=10;
555}}Z=Math.floor(Z/i)*i;
556F=Math.ceil(F/i)*i;
557var E=1;
558if(M>1){while(E*20<M){E*=10;
559}}else{while(E<M*20){E/=10;  //  <#  This is where things get trapped
when M = 1 and E=1
560}}g=Math.floor(g/E)*E;
561H=Math.ceil(H/E)*E;

As can be seen, the loop at 559 can't escape since E only gets smaller and
can't break out from condition ''E<M*2"

Eric
_______________________________________________
General mailing list
[email protected]
http://simile.mit.edu/mailman/listinfo/general

Reply via email to