How to calculate Pearson correlation values of two columns in KNIME


#1

I am quite new to KNIME. If I have a dataframe like:

Key   Old   New   cor
 A    30    40
 A    20    15
 B    25    30
 B    28    65
 B    11    19

And I would like to calculate the pearson correlation values of OLD and New these two columns which are grouped by Key. Could anyone teach me with this? Thanks for your time!


#2

Hi @yurunsang

you need the linear correlation node for calculating this. It will output you the correlation matrix.

Best wishes, Iris


#3

Hi Iris,
Thanks for telling me this. However, I need it group by key so I need to know the correlation values of key A and key B individually. Could it be realised in ‘linear correlation’? Thanks.
Best regards,
Runsang