http://redmine.emweb.be/http://redmine.emweb.be/favicon.ico?16934085252014-04-12T09:04:02ZRedmineWt - Feature #2905: axis autoscalehttp://redmine.emweb.be/issues/2905?journal_id=89242014-04-12T09:04:02ZKoen Deforchekoen@emweb.be
<ul><li><strong>Status</strong> changed from <i>New</i> to <i>Feedback</i></li><li><strong>Assignee</strong> set to <i>Koen Deforche</i></li></ul><p>Hey,</p>
<p>When you want an automatic axis scale but only have a single data point, then the axis does not really know what resolution you want. You can indicate it with axis.setResolution().</p>
<p>For example, in this case, an axis.setResolution(0.1) could be appropriate.</p>
<p>Regards,<br><br>
koen</p>
Wt - Feature #2905: axis autoscalehttp://redmine.emweb.be/issues/2905?journal_id=89412014-04-15T13:49:36ZСтойчо Стефанов Stoycho Stefanov
<ul></ul><p>Hey,</p>
<p>perhaps you could consider the following automatic axis scale when the chart has equal data points in some dimension (pseudo code):</p>
<pre><code>if (chart_.series(0).min() == chart_.series(0).max()){
double value = chart_.series(0).min();
...
double res = exp10(floor(log10(value)) - 1);
yAxis.setResolution(res);
}
</code></pre>
<p>For me it seems reasonable.</p>
<p>Regards,<br><br>
Stoycho</p>