Splunk Search

How i can calculate average of each event type

Amandeepsin
New Member

index="sc-general" info AND(heartbeat OR Successfully) NOT(created) | rex ":\s+(?\w+)" | eval entry_type=if(entry_type == "Successfully", "File", entry_type) | timechart count by entry_type

Now, I want to calculate average of each event type on this chart. help me with this

Tags (1)
0 Karma

Richfez
SplunkTrust
SplunkTrust

Your search came through a bit garbled, but I believe you can just change your timechart at the end to

| timechart count, avg(MyField) by entry_type

filling in whatever "MyField" that you wanted to average was.

0 Karma

Richfez
SplunkTrust
SplunkTrust

If this worked for you, could you please Accept the Answer so that others searching here will benefit?

Thanks!
Rich

0 Karma
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 ...