# Comparing correlation coefficients

I have two sets of data where I have at ~250.000 values for 78 and 35 samples. Some of the samples are members of a family and this may have an effect of the data. I have calculated pairwise correlation and it varies between 0.7 and 0.95 but I would like to know if there is significant difference in correlation coefficients intra vs inter family? What is the best way to do this? Thanks

A general way to compare two correlation coefficients $\hat{\rho}_{1}, \hat{\rho}_{2}$ is to use Fisher's z-transform method, which says that ${\rm arctanh}(\hat{\rho})$ is approximately normal with mean ${\rm arctanh}(\rho)$ and standard deviation $1/\sqrt{n-3}$. If the samples are independent, then you transform each correlation coefficient and the difference between the two transformed correlations will be normal with mean ${\rm arctanh}(\rho_{1})-{\rm arctanh}(\rho_{2})$ and standard deviation $\sqrt{1/(n_{1}-3) + 1/(n_{2}-3)}$. From this you can form a $z$-statistic and do testing as you would in an ordinary two-sample $z$-test.