All Apps and Add-ons

SPLUNK enterprise i am trying to calculate results where > 4% of failure  is my formula correct , to set anomaly ?

maulik29
Engager

i am trying to calculate results where > 4% of failure  is my formula correct , to set anomaly ? 

| inputlookup  sample.csv | eval isananomaly = if('Failcount' / 'Totalcount' * 100 > 4 ,  1 , 0)

Labels (1)
0 Karma
1 Solution

richgalloway
SplunkTrust
SplunkTrust

Because of integer arithmetic, I prefer to use 

| inputlookup  sample.csv | eval isananomaly = if((Failcount * 100 / Totalcount) > 4 ,  1 , 0)
---
If this reply helps you, Karma would be appreciated.

View solution in original post

richgalloway
SplunkTrust
SplunkTrust

Because of integer arithmetic, I prefer to use 

| inputlookup  sample.csv | eval isananomaly = if((Failcount * 100 / Totalcount) > 4 ,  1 , 0)
---
If this reply helps you, Karma would be appreciated.
Get Updates on the Splunk Community!

Introduction to Splunk Observability Cloud - Building a Resilient Hybrid Cloud

Introduction to Splunk Observability Cloud - Building a Resilient Hybrid Cloud  In today’s fast-paced digital ...

Observability protocols to know about

Observability protocols define the specifications or formats for collecting, encoding, transporting, and ...

Take Your Breath Away with Splunk Risk-Based Alerting (RBA)

WATCH NOW!The Splunk Guide to Risk-Based Alerting is here to empower your SOC like never before. Join Haylee ...