Splunk Search
Highlighted

How to set the Background Color of a Chart?

Path Finder

Hi,

We want to represent two Criticality Zones for an attribute on a Chart. Based on a Critical Threshold Series (we are calling it a Series because the values of Critical Threshold varies all throughout the Day), there should be two Criticality Zones on the Chart:

  1. Normal Zone - The entire area below the Critical Threshold Series should be Normal Zone (denoted by a Green colour)
  2. Critical Zone - The entire area above the Critical Threshold Series should be Critical Zone (denoted by a Red colour)

To handle the above mentioned scenario, we want to set the Background Colour of the Chart to Red, and super-impose the Green Zone on it. We tried setting the Background Colour using the charting.backgroundColor option, but that colours the entire Chart component (including Legends and Labels), instead of just the actual Charting area.

Could you please let us know how to set the Background Colour for just the Chart Area.

Highlighted

Re: How to set the Background Color of a Chart?

New Member

Does anyone has any idea about this?

0 Karma
Highlighted

Re: How to set the Background Color of a Chart?

Communicator

You need to write custom javascript that does the trick for you. I hope you are doing this in webframework and hence you can include your js within the page and read the value from the javascript and then based on the value, you can set it to either green or red.

0 Karma