Is it possible to set custom colors for Lens filters on a Pie/Donut?

Trying to convert legacy visualizations to Lens ones, and the thing that's sticking out to me as a sore spot is that I can't figure out how to get specific colors for keywords/filters.

The colors in Lens group into the pallete from largest to smallest it seems, which makes bad runs look good from a color perspective.

While in Legacy I could set the colors to make sense.:

Note: We're currently running 7.12, so if this happens to be in .13/.14 I'll poke our admins.

In 7.14 Elastic introduced custom color coding based on values for lens visualizations.
So upgrade will solve your issue.

1 Like

It's not possible to fully control the color-assignment right now, but if you are using filters you can achieve something similar by ordering the filters in the right way. For example if the status color palette is used, and you want "passed" to be green, "failed" to be red and "skipped" to be yellow, then specify the status: passed filter first, then the status: skipped filter, then the status: failed one.

This doesn't seem to be working for me in 7.12, but I'm talking with our admins to see if we can get onto 7.14.

The Filter reordering trick will work for bar/area/line charts but unfortunately not yet for pie charts @PanoramicPanda .

We have an active issue for this type of feature and you could track its development progress: [Lens] Support categorical coloring by name · Issue #101942 · elastic/kibana · GitHub

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