First correlation_test() version (replacing previous chisquare_test)