Dashboards & Visualizations

If color - single value

mansel_scheffel
Explorer

Hi,

I have a form that has several single value visuals on them populated by a lookup(not numbers).. I have created dropdown menus that im hoping i can use to influence/change the colors..

So basically the default block colour must always be red, but then I want to change it to any of the 3 other colours in the range via the dropdown box.

I was thinking along the lines of using a token from the dropdown which would represent a number and insert that into an eval statement with rangemap etc.. No idea how to write it out basically.. Any thoughts ?

Thanks!

0 Karma
1 Solution

gcusello
SplunkTrust
SplunkTrust

use eval and case in your search to set a value to every status you want to represent and use this value to set the color:
e.g. | eval range=case(field=Rome,1,field=Parigi,2,field=London,3....).
After you are able to not show this value using the field tag.
See how to do this in the dashboard example "Table Element with Hidden Fields".
Bye.
Giuseppe

View solution in original post

0 Karma

gcusello
SplunkTrust
SplunkTrust

use eval and case in your search to set a value to every status you want to represent and use this value to set the color:
e.g. | eval range=case(field=Rome,1,field=Parigi,2,field=London,3....).
After you are able to not show this value using the field tag.
See how to do this in the dashboard example "Table Element with Hidden Fields".
Bye.
Giuseppe

0 Karma
Get Updates on the Splunk Community!

Detecting Remote Code Executions With the Splunk Threat Research Team

REGISTER NOWRemote code execution (RCE) vulnerabilities pose a significant risk to organizations. If ...

Observability | Use Synthetic Monitoring for Website Metadata Verification

If you are on Splunk Observability Cloud, you may already have Synthetic Monitoringin your observability ...

More Ways To Control Your Costs With Archived Metrics | Register for Tech Talk

Tuesday, May 14, 2024  |  11AM PT / 2PM ET Register to Attend Join us for this Tech Talk and learn how to ...