r_crit | R Documentation |
Calculate critical value for correlation coefficient,
for a given sample size and confidence level.
If absolute value of an observed correlation coefficient is higher
than the critical value, then the correlation is statistically significant
with the specified confidence.
This approach is
identical to using textbook tables of critical values and
alternative to calculating p
-values.
r_crit(n, conf.level = 0.95, method = c("t"))
n |
sample size(s) used to calculate correlations.
Values of |
conf.level |
confidence level for calculating the critical value(s). Default is 0.95 (i.e., confidence of 95%). If length of the input is higher than 1, only the first element is used. |
method |
Method for calculating the critical values.
Currently only the method based on |
Using Student's t
-distribution, the critical value is
r_{crit} = \frac{t}{\sqrt{n - 2 + t^2}},
where t
is a quantile of t
-distribution with
n - 2
degrees of freedom for probability 1 - (1 - conf.level)/2
.
A vector of critical values.
Vyacheslav Lyubchich
cor.test
, cor
r_crit(120)
r_crit(20:30, conf.level = 0.9)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.