Splunk Search

How to search the average of one field by values of another field, then chart them side by side?

jasoholt
Engager

I am very new to Splunk and trying to learn manipulation like I would in Excel. My current task is to get an average of a result, and then display it by a device type. Let's assume the CSV looks like this:

DEVICE, RATIO
iphone, 20
iphone, 10
iphone, 15
samsung, 30
samsung, 12
samsung, 83

I want to get the average of the Ratios, by Device Type. And then Chart them side by side.

iphone 15
samsung 42

0 Karma

renjith_nair
Legend

Try this

your search |stats avg(RATIO) by DEVICE

OR

    your search |eventstats avg(RATIO) by DEVICE

If you want to repeat the values in each row

Happy Splunking!

renjith_nair
Legend

@jasoholt, please accept as 'answer' if it resolves your issue so that the thread will be closed

Happy Splunking!
0 Karma
Get Updates on the Splunk Community!

Announcing Scheduled Export GA for Dashboard Studio

We're excited to announce the general availability of Scheduled Export for Dashboard Studio. Starting in ...

Extending Observability Content to Splunk Cloud

Watch Now!   In this Extending Observability Content to Splunk Cloud Tech Talk, you'll see how to leverage ...

More Control Over Your Monitoring Costs with Archived Metrics GA in US-AWS!

What if there was a way you could keep all the metrics data you need while saving on storage costs?This is now ...