ASE Home Page Products Download Purchase Support About ASE
ChartDirector Support
Forum HomeForum Home   SearchSearch

Message ListMessage List     Post MessagePost Message

  Auto Scale Failing?
Posted by Pete-R on Sep-19-2008 06:18
Attachments:
Peter,

Any idea why Auto Scale does this when I move the Year back from 1964 to 1963 (or earlier)

Cheers,

Pete.
auto_scale.png

  Re: Auto Scale Failing?
Posted by Peter Kwan on Sep-19-2008 17:50
Hi Pete-R,

The reason is not because of the x-axis, but because of the y-data range.

By default, if the data fluctuation is "large" (over 20%), ChartDirector will start the y-axis from 0. If the data fluctuation is small, ChartDirector will not prefer to start the y-axis from 0.

For example, if the data range is 30 - 160, ChartDirector will start the y-axis from 0. If the data range is 30.0001 to 30.0007, ChartDirector will not start the y-axis from 0.

The above is configurable using Axis.setAutoScale.

If you do not what ChartDirector to prefer to start the y-axis from 0 in any case, you may use:

#set the zero affinity parameter to 0
$c->yAxis->setAutoScale(0.05, 0.05, 0);

Hope this can help.

Regards
Peter Kwan

  Re: Auto Scale Failing?
Posted by Pete-R on Sep-19-2008 21:10
Peter,

Thanks again. It now works as I envisaged!

Cheers,

Pete.