Advanced Graphing (Part1): Style Overrides

Series Overrides

You can customize display options on a per series bases, or by using regex rules.

You find series override in Display tab:

After you click on Add override you specify a series name or regex by wrapping the expression in / chars. Then you can use the plus button to add any override.

Color & Point Overrides

In the above graph you can see points, lines and y-axis overrides using regex rules:

Of course you can easily change series color by clicking the colored icon to the left of the series name in the legend. But with the series override you set color using a regex!

Stack Group & Transform Negative

Above we use 2 different stack groups to stack in and out data separately, we also use the negative-y transform to visualize the in series on the negative-y axis (without affecting the hover & legend values).

Options:

Fill Below To

If you have want to graph min, max & avg of some metric you can take advantage of series overrides to customize the look for each series.

So while writing this post I notiticed that there is a bug when adding the Fill below to override (fixed in master). So if nothing happens after you select the min series, switch tab and go back to Display tab. You should see the fill below to override being set. What is not set (due to the bug) is another override that should be added automatically (but is not due to the bug).

So add another override. Specify min as the alias regex and add override Lines false.
So options should look like this:

11 Likes

@torkel
It’s a very useful feature! Thanks.
I wonder, if there any way to assign metric to axis by its content?
For example, I query Elasticsearch with specific hostname and metric name, is it possible to assign metric values to a specific axis using regex applied to metric name?
Example query:
host.keyword:$host AND (item_name.keyword:$metric)
$metric contains something like "Memory used (%)"
Thanks in advance. :slight_smile:

Yes use can use a regex or alias name rule and specify y-axis as the override option

Can you please go into more detail about this sections: Stack Group & Transform Negative?

How exactly did you group the series’ together. I’m basically trying to do the exact same thing with traffic from a SAN.

@torkel Its a very useful option. I want to display series override in table panel.
/cpu/ - red color, /memory/ - green. I don’t see series override option in table panel. Is there a possibility to add this feature in table panel? Thanks

Ah … gold! Thank you for this short series. I did the negative Y-axis with math(* -1) until now, because that looked like the obvious solution to my mind …

Patrick

I guess that’s count as necro posting, but where to find this options in current Grafana? When i try to create override i get this
image
image

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.