Skip to content

Find the cutoff correlation value for Pearson correlation test

4 messages · John, Jim Lemon, David L Carlson

#
On 11/15/2013 12:53 PM, jpm miao wrote:
Hi Miao,
Perhaps you could use the confidence interval.

Jim
#
I haven't looked at fBasics::correlationTest, but cor.test uses
the t distribution to evaluate significance:

t = sqrt(df) * r/sqrt(1 - r^2)

where df=n-2

If you solve that for r, you get

r = t/sqrt(t^2+100-2)

If you choose t as qt(.975, df) for a two-tailed test at p<.05
you can plug in t and place your limits at +/- of that value. Eg
for 100 observations:
[1] 1.984467
[1] 0.1965512
-------------------------------------
David L Carlson
Department of Anthropology
Texas A&M University
College Station, TX 77840-4352

-----Original Message-----
From: r-help-bounces at r-project.org
[mailto:r-help-bounces at r-project.org] On Behalf Of Jim Lemon
Sent: Thursday, November 14, 2013 9:44 PM
To: jpm miao
Cc: r-help
Subject: Re: [R] Find the cutoff correlation value for Pearson
correlation test
On 11/15/2013 12:53 PM, jpm miao wrote:
that
, e.g., p =
series, and I
significance of the
Hi Miao,
Perhaps you could use the confidence interval.

Jim

______________________________________________
R-help at r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide
http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible
code.
#
I should have added, that these limits are not been corrected
for multiple comparisons. With 1000 tests, we expect about 50 to
be outside the limits. So you might want to use p.adjust() to
take multiple comparisons into account.

David

-----Original Message-----
From: r-help-bounces at r-project.org
[mailto:r-help-bounces at r-project.org] On Behalf Of David Carlson
Sent: Friday, November 15, 2013 9:42 AM
To: 'Jim Lemon'; 'jpm miao'
Cc: 'r-help'
Subject: Re: [R] Find the cutoff correlation value for Pearson
correlation test

I haven't looked at fBasics::correlationTest, but cor.test uses
the t distribution to evaluate significance:

t = sqrt(df) * r/sqrt(1 - r^2)

where df=n-2

If you solve that for r, you get

r = t/sqrt(t^2+100-2)

If you choose t as qt(.975, df) for a two-tailed test at p<.05
you can plug in t and place your limits at +/- of that value. Eg
for 100 observations:
[1] 1.984467
[1] 0.1965512
-------------------------------------
David L Carlson
Department of Anthropology
Texas A&M University
College Station, TX 77840-4352

-----Original Message-----
From: r-help-bounces at r-project.org
[mailto:r-help-bounces at r-project.org] On Behalf Of Jim Lemon
Sent: Thursday, November 14, 2013 9:44 PM
To: jpm miao
Cc: r-help
Subject: Re: [R] Find the cutoff correlation value for Pearson
correlation test
On 11/15/2013 12:53 PM, jpm miao wrote:
that
, e.g., p =
series, and I
significance of the
Hi Miao,
Perhaps you could use the confidence interval.

Jim

______________________________________________
R-help at r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide
http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible
code.

______________________________________________
R-help at r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide
http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible
code.