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!

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

Introducing the 2024 SplunkTrust!

Hello, Splunk Community! We are beyond thrilled to announce our newest group of SplunkTrust members!  The ...

Introducing the 2024 Splunk MVPs!

We are excited to announce the 2024 cohort of the Splunk MVP program. Splunk MVPs are passionate members of ...