Splunk Search

Hello experts, I would like to calculate the pearson correlation between all my fields ?

faisal_alazem
New Member

I visited the documentation and I see that we can only compute the pearson correlation between two fields at a time with command |score pearsonr field_a against field_b . How can I computer the pearson correlation between all the fields in my data ? Assuming I have a dataset with 5 columns, my output should give me 32 pairs of pearson correlations.

In a programming language this can be easily coded with a double for loop. I am wondering how to do this in splunk.

Thank you

Tags (2)
0 Karma

jraso
Explorer

Hi Faisal,

I managed to do that yesterday following these steps from the MLTK documentation:

https://docs.splunk.com/Documentation/MLApp/5.1.0/API/CorrelationMatrix

Hope it helps!

0 Karma
Get Updates on the Splunk Community!

Index This | I am a number, but when you add ‘G’ to me, I go away. What number am I?

March 2024 Edition Hayyy Splunk Education Enthusiasts and the Eternally Curious!  We’re back with another ...

What’s New in Splunk App for PCI Compliance 5.3.1?

The Splunk App for PCI Compliance allows customers to extend the power of their existing Splunk solution with ...

Extending Observability Content to Splunk Cloud

Register to join us !   In this Extending Observability Content to Splunk Cloud Tech Talk, you'll see how to ...