I have two variables where the regression line is just the mean as a constant. As such, the correlation is zero. However, when I perform k-fold cross validation (in Weka) this becomes non-zero.(adsbygoogle = window.adsbygoogle || []).push({});

I have no idea why this is. The regression line for whatever the test set is will always be a constant, where the correlation will be zero. Because some of the data will be taken out to act as the validation set at each fold the mean will be different at each fold, but the correlation will still be the same no matter what. The only thing I can think of is that it is computing the correlation between training means with respect to the actual mean, but even then these should sum to zero.

Can anybody clear this up for me?

**Physics Forums | Science Articles, Homework Help, Discussion**

Join Physics Forums Today!

The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

# The effect of cross validation on correlation coefficient

Can you offer guidance or do you also need help?

Draft saved
Draft deleted

**Physics Forums | Science Articles, Homework Help, Discussion**