# TSVB Metric color based on text field and numeric value

**URL:** <https://discuss.elastic.co/t/tsvb-metric-color-based-on-text-field-and-numeric-value/263570>\
**Category:** Kibana\
**Created:** [February 8, 2021, 10:01am UTC](https://discuss.elastic.co/t/tsvb-metric-color-based-on-text-field-and-numeric-value/263570 "2021-02-08T10:01:25Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Chenlrv](https://avatars.discourse-cdn.com/v4/letter/c/c5a1d2/32.png) [@Chenlrv](https://discuss.elastic.co/u/Chenlrv)\
**Post date:** [February 8, 2021, 10:01am UTC](https://discuss.elastic.co/t/tsvb-metric-color-based-on-text-field-and-numeric-value/263570/1 "2021-02-08T10:01:25Z")

</div>

Hi,  
I created a TSVB Metric widget that it's purpose is to function as a traffic light - should be red when there's an error in the system, yellow if there's a warning, and green if all is ok.  
 ![image](https://us1.discourse-cdn.com/elastic/original/3X/c/3/c3cdb015d84cefc32c4fef9bd15868bd96c2da99.png)  
The problem is, I can't find a way to configure 3 different colors based on the "status" field ("error","warning","ok") and on the numeric value.  
For now, I succeeded to configure green and red colors like this -

 ![image](https://us1.discourse-cdn.com/elastic/original/3X/8/b/8b689769a945a5db03c327fa3d09f734fea9970b.png)  
I really want to find out how to configure color based on the status and on the numeric value... is that possible somehow? I tried using Markdown widget also but it doesn't look as good as the Metric vis.  
Thanks

---

<div class="post-metadata">

**Author:** ![Marius\_Dragomir](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/marius_dragomir/32/42087_2.png) [@Marius\_Dragomir](https://discuss.elastic.co/u/Marius_Dragomir)\
**Post date:** [February 9, 2021, 5:18pm UTC](https://discuss.elastic.co/t/tsvb-metric-color-based-on-text-field-and-numeric-value/263570/2 "2021-02-09T17:18:36Z")

</div>

It doesn't really work that well with string values, it works on numeric values. What I would suggest is have 2 different TSVB metric visualizations, one that goes Green/Red if there are any Error ones and another one that goes Green/orange if there are any warnings.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [March 9, 2021, 5:19pm UTC](https://discuss.elastic.co/t/tsvb-metric-color-based-on-text-field-and-numeric-value/263570/3 "2021-03-09T17:19:06Z")

</div>

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