Splunk Search

How to overlay daily avg on count per day using timechart?

jwalzerpitt
Influencer

I have the basic search of for count by day

index=foo
| bin _time span=1d 
| timechart count

How can I overlay the daily avg of count per day?

Thx

0 Karma

to4kawa
Ultra Champion
| tstats count where index=foo prestats=t by _time span=1d
| timechart count
| eventstats avg(count) as daily_avg

Visualization with overlay daily_avg
How about this?

jpolvino
Builder

Can you please elaborate, or possibly provide some examples? The count per day is just that: a single value. What are you trying to average? The timechart command itself allows bucketing by day with the span=1d option, and can perform statistical aggregations including avg and count.

0 Karma
Career Survey
First 500 qualified respondents will receive a $20 gift card! Tell us about your professional Splunk journey.

Can’t make it to .conf25? Join us online!

Get Updates on the Splunk Community!

Take Action Automatically on Splunk Alerts with Red Hat Ansible Automation Platform

 Are you ready to revolutionize your IT operations? As digital transformation accelerates, the demand for ...

Calling All Security Pros: Ready to Race Through Boston?

Hey Splunkers, .conf25 is heading to Boston and we’re kicking things off with something bold, competitive, and ...

Beyond Detection: How Splunk and Cisco Integrated Security Platforms Transform ...

Financial services organizations face an impossible equation: maintain 99.9% uptime for mission-critical ...