Dashboards & Visualizations

pie percentage data

kfir
New Member

hello

I have a pie chart and added the command to show percentage and this is the query that I am using
|inputlookup ICC_activities | stats count by ITMU | eval ITMU=ITMU.": ".count
the output is that it show ITMU: ,

I would like to know 2 things
1. what and how I need to edit the command to show the percentage inside the pie chart and not near.
2. how I need to edit the command to round the percentage with 2 numbers or no decimal numbers at all (tried to add | eval percent=round(percent,0) to the end, but not successfully.
thank in advance
kfir

Tags (2)
0 Karma

woodcock
Esteemed Legend

To make your search "work", do this:

|inputlookup ICC_activities | top ITMU | eval ITMU=ITMU . ":" . round(percent,3) . "%" 
| fields - percent

But this will not do what you are asking. To get both the count and the percent inside the pie pieces, upgrade to v6.6 where this happens automatically (I do not know when this feature went it but it is in v6.6).

0 Karma

niketn
Legend

@kfir...

1) Showing Stats inside might not possible without JS/CSS extension. You can try to Donut Custom Visualization. However, the same is not Built/Supported by Splunk. https://splunkbase.splunk.com/app/3238/

2) Refer to my answer on similar question: https://answers.splunk.com/answers/351010/how-to-round-a-percentage-value-in-a-pie-chart-to.html#ans...

____________________________________________
| makeresults | eval message= "Happy Splunking!!!"
0 Karma
Get Updates on the Splunk Community!

Splunk Observability Cloud's AI Assistant in Action Series: Auditing Compliance and ...

This is the third post in the Splunk Observability Cloud’s AI Assistant in Action series that digs into how to ...

Splunk Community Badges!

  Hey everyone! Ready to earn some serious bragging rights in the community? Along with our existing badges ...

What You Read The Most: Splunk Lantern’s Most Popular Articles!

Splunk Lantern is a Splunk customer success center that provides advice from Splunk experts on valuable data ...