# Color range on Metric Widget not working on Average Metric

**URL:** <https://discuss.elastic.co/t/color-range-on-metric-widget-not-working-on-average-metric/296737>\
**Category:** Kibana\
**Created:** [February 9, 2022, 2:33pm UTC](https://discuss.elastic.co/t/color-range-on-metric-widget-not-working-on-average-metric/296737 "2022-02-09T14:33:41Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![despinola](https://avatars.discourse-cdn.com/v4/letter/d/ed655f/32.png) [@despinola](https://discuss.elastic.co/u/despinola)\
**Post date:** [February 9, 2022, 2:33pm UTC](https://discuss.elastic.co/t/color-range-on-metric-widget-not-working-on-average-metric/296737/1 "2022-02-09T14:33:41Z")

</div>

I have a dashboard that is using a color range on two metrics:

- The first one is a numeric field (count) and the color range works perfectly.
- The problem appears on the second metric which is also numeric but is an **Average instead of Count**. In this case, color ranges are not working.

Is this an issue or am I doing something wrong?

 ![image](https://us1.discourse-cdn.com/elastic/original/3X/b/4/b4ad9c2c8676f117bafb105407efc6632bab82d6.png)  
 ![image](https://us1.discourse-cdn.com/elastic/original/3X/a/a/aa5f306680e3009f10e4aaf47f60fe26ed60e332.jpeg)

Many thanks!

---

<div class="post-metadata">

**Author:** ![Stratoula\_Kalafateli](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/stratoula_kalafateli/32/70923_2.png) [@Stratoula\_Kalafateli](https://discuss.elastic.co/u/Stratoula_Kalafateli)\
**Post date:** [February 9, 2022, 2:43pm UTC](https://discuss.elastic.co/t/color-range-on-metric-widget-not-working-on-average-metric/296737/2 "2022-02-09T14:43:11Z")

</div>

Hey! What version of kibana are you using?  
Can you also share a screenshot of how metric chart looks?

---

<div class="post-metadata">

**Author:** ![despinola](https://avatars.discourse-cdn.com/v4/letter/d/ed655f/32.png) [@despinola](https://discuss.elastic.co/u/despinola)\
**Post date:** [February 9, 2022, 2:58pm UTC](https://discuss.elastic.co/t/color-range-on-metric-widget-not-working-on-average-metric/296737/3 "2022-02-09T14:58:34Z")

</div>

I am using  
v 7.10.2

This is the edition view of the chart: (deployments/week is ok, the hours not)

 ![image](https://us1.discourse-cdn.com/elastic/original/3X/e/1/e1340e228a3e82599c6d2061b2ac996479705635.png)

And this is the chart with real data:  
 ![image](https://us1.discourse-cdn.com/elastic/original/3X/a/5/a57c5d64ab95e0d6d355a607976c658f26d86c10.png)

---

<div class="post-metadata">

**Author:** ![Stratoula\_Kalafateli](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/stratoula_kalafateli/32/70923_2.png) [@Stratoula\_Kalafateli](https://discuss.elastic.co/u/Stratoula_Kalafateli)\
**Post date:** [February 9, 2022, 3:48pm UTC](https://discuss.elastic.co/t/color-range-on-metric-widget-not-working-on-average-metric/296737/4 "2022-02-09T15:48:26Z")

</div>

The `-` is coloured green because it is treated as 0. This is a bit confusing I know.  
About the 41.32 (the red one on the second screenshot) I cant reproduce it tbh. So you are expecting green here right? Because it falls on the first rule [0, 48], right?

---

<div class="post-metadata">

**Author:** ![despinola](https://avatars.discourse-cdn.com/v4/letter/d/ed655f/32.png) [@despinola](https://discuss.elastic.co/u/despinola)\
**Post date:** [February 9, 2022, 4:04pm UTC](https://discuss.elastic.co/t/color-range-on-metric-widget-not-working-on-average-metric/296737/5 "2022-02-09T16:04:25Z")

</div>

Yes, I would expect green because it fits on the first rule [0,48]. I've also tried setting the range as float numbers but it is not also working.

---

<div class="post-metadata">

**Author:** ![Stratoula\_Kalafateli](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/stratoula_kalafateli/32/70923_2.png) [@Stratoula\_Kalafateli](https://discuss.elastic.co/u/Stratoula_Kalafateli)\
**Post date:** [February 10, 2022, 6:38am UTC](https://discuss.elastic.co/t/color-range-on-metric-widget-not-working-on-average-metric/296737/6 "2022-02-10T06:38:20Z")

</div>

Can you send me the saved object of this visualization? It might help me to replicate the issue. Also the mapping of the `maxCommitsLeadTime. `Thanx!

---

<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 10, 2022, 6:39am UTC](https://discuss.elastic.co/t/color-range-on-metric-widget-not-working-on-average-metric/296737/7 "2022-03-10T06:39:02Z")

</div>

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