elastic / kibana

Your window into the Elastic Stack
https://www.elastic.co/products/kibana
Other
19.72k stars 8.13k forks source link

Enhancement: color list for topN queries #1121

Closed faxm0dem closed 9 years ago

faxm0dem commented 10 years ago

When using a topN query, it is currently only possible to choose one color, which then generates a nice gradient. Sometimes it is more relevant to use a color list, e.g. ['red','green'] corresponding for instance to ['Reject','Accept']. This would allow for increased contrast.

jmcle commented 10 years ago

+1. I currently use topN to draw a histogram of requests per user over time. With a graph like this it make more sense to have a contrasting color palette instead of a gradient. Having a drop down with options like 'gradient, contrasting, or custom' would be excellent.

ntfrnzn commented 10 years ago

agreed -- topN is most useful for comparing frequencies, and while the gradient is very tasteful, clashing colors would be more informative.

faxm0dem commented 10 years ago

the following would seem a quite sane approach: http://martin.ankerl.com/2009/12/09/how-to-create-random-colors-programmatically/

ralphm commented 10 years ago

I'd also love to see a feature where you'd not get the gradient but clashing colors. I really like the approach taken by Grafana, where you can click on the label in a graph's legend and set the color for the matching metric there. This also works for metrics series (as opposed to just one), so that would be kinda similar to topN. Grafana then just keeps a mapping of label names and colors. I suppose that for Kibana it would be nice if this list is tied to the query, so that the selected colors are consistent between multiple graphs (like a histogram and a hits panel)

JulienPalard commented 10 years ago

+1 here too, I'm using a topN to feed an histogram with bars. My topN is on a "hostname" field, I'd like to use the dominant color of the favicon of the website instead of a gradient, so my brains can match it faster. Also, the gradient use some quasi indistinguisable colors, it's almost impossible to read while approching brightest colors.

JulienPalard commented 10 years ago

An idea permitting uniformiasation may be to globally assign color to given values.

Using this technique we'll be able to use the right color independently of the source (topN + stats or lucene + terms), this fixes others bug about color coherence between terms panels.

tylerjl commented 10 years ago

+1

While topN is a nice replacement for derivequeries, the lack of contrast in comparison with the queries derivequeries generated is a pretty big break in the use case we've been leveraging it for.

quentinchap commented 10 years ago

+1 the gradient isn't always visible.

danmilon commented 9 years ago

I agree, the current coloring scheme works for limited applications.

rashidkpc commented 9 years ago

The top N query has been deprecated as nested aggregations are much faster. We've introduced better color logic for them in Kibana 4