Nevron Forum

Autoscaling the Y axis based on subset of data

https://www.nevron.com/Forum/Topic8184.aspx

By Ronnie Cohen - Thursday, September 26, 2013

If I have one year of data with a range of values of 0 to 400,000 and I choose to see a subset of the data for one month that contains values from 0 to 50,000, is it possible to configure the Y axis to automatically rescale to fit the data range shown in the chart? I have a request to scale the Y axis based on the range of values in the current view in the chart. How can I do that with Nevron charts?
By Nevron Support - Friday, September 27, 2013

Hi Ronnie,

How do you configure the chart to show only a subset of data - by using the axis view or simply by adding that subset of data to the chart? If you use view the control will always use the 0-400K range whereas when you use a subset it will use that subset to calculate the y range.

By Ronnie Cohen - Friday, October 4, 2013

I have a charting facility that initially shows the whole range in a chart. A paging control is used with the chart to enable users to see a day, week, month or year of data within that range and some navigation buttons to go the first/previous/next/last day/week/month/year within the data set and show the result in the chart.

The attached files show the whole range and a subset of the range. In both cases, the Y axis is scaled based on the whole range. I wonder whether the Y axis can be automatically scaled to reflect the data range of the data shown in the chart. In the attached Subset_Range.png image, I would like the Y axis to be automatically scaled for the highest and lowest values for the month of data shown in the chart. Can the Y axis be automatically scaled to reflect the range of values for the data shown in the chart (like the data shown in the attached Subset_Range.png image)?
By Nevron Support - Monday, October 7, 2013

Hi Ronnie,

This cannot be achieved out of the box, however it can be done if you specify a range to the y axis from code using the NRangeAxisView object depending on the x axis min / max values.