Is it possible to have min and max values for a graph that still allow the graph to autoscale itself but only within the range I specify? What I find often happens is that I get one high values that I’m not interested in, so I set the min and max to say, 0 and 100. But then if my data is mostly low the graph just looks like a straight line at the bottom. I want it to autoscale but not autoscale outside 0 to 100. Is there any way to do that? I also find that if my data is always zero then Grafana shows from say -10 to 10 indicating that the data might be able to be negative when that is not the case. So it could be useful in that case also.
Yes there is a way to do this.
Let suppose you have a data point which lies between 0 to 500 . And you want to plot these points in between 0 to 100. Do one thing in a query divide your points to 5 then all values will be lies between 0 to 100 and you can select min and max value from visualization style by providing min and max values.
StartTime as time,
(Columnname/5) as value
Here is a example. I hope this will be helpful. Try this and do let me know if you have any issue.
Thanks for the reply but that’s not what I want to do. I simply want to not allow the axis to extend past 0 and 100. If a point is at 500 it should be drawn off the graph, so that you might see part of the line extending up off the top of the chart but you wouldn’t see that data point. At the same time, if the data was only from 0 to 50 then the axis would be from 0 to 50
this is an older request, but a very valid one. I am looking for exactly the same. Sometimes there is one tiny huge peak in a 24h series, making the whole chart almost unusable. Due to one single 7.7k peak the y-axis is scaled to 10k max, while all other values hover around 0-1000. This makes then for mostly a flatline of all shown other data. As you say, the one peak is really not relevant, so I‘d like to have autoscaling in general, but never more than 5k on the y-axis.