Dashboards & Visualizations

How to control the colors for a pie chart?

athorat
Communicator

I am trying to use specific colours while using pie charts

Pie chart displays Response Time in milliseconds and its is divided , starting from : " < 50 ms" , "Between 50 to 100 ms" ,
"Between 100 to 250 ms" , "Between 250 to 500 ms " and " > 500 ms"
So the colours should be from green to Yellow to Amber to Orange to Red Respectively.

Can you please have a look at the below entries from the source xml and help me correct the following.
Or may be any other way to control the colours for the chart.

<option name="charting.chart.rangeValues">["< 50 ms","Between 50 ms To 100 ","Between 100 ms To 250 ms","Between 250 ms To 500 ms", "> 500 ms"]</option

<option name="charting.seriesColors">[0xbf3030,ms#ccff00,0x84e900,0xFFFF00,0xFF0000]</option>

Thanks for looking into this

Tags (3)
0 Karma

ramdaspr
Contributor

Assuming that your query responds with the field names " < 50 ms" , "Between 50 to 100 ms" ,
"Between 100 to 250 ms" , "Between 250 to 500 ms " and " > 500 ms"

you can use

 <option name="charting.fieldColors">{"<50 ms":0x00ff00,"Between 50 to 100 ms":0x33ff00,"Between 100 to 250 ms":0x66ff00,"Between 250 to 500 ms":0xffaa00,304:0xffff00,"> 500 ms":0xff0000}</option>
Get Updates on the Splunk Community!

Webinar Recap | Revolutionizing IT Operations: The Transformative Power of AI and ML ...

The Transformative Power of AI and ML in Enhancing Observability   In the realm of IT operations, the ...

.conf24 | Registration Open!

Hello, hello! I come bearing good news: Registration for .conf24 is now open!   conf is Splunk’s rad annual ...

ICYMI - Check out the latest releases of Splunk Edge Processor

Splunk is pleased to announce the latest enhancements to Splunk Edge Processor.  HEC Receiver authorization ...