Sample size planning for a desired Pearson's correlation confidence interval
Source:R/corr_ss.R
corr_ss.Rd
Find the required (sufficient) sample size for computing a Pearson correlation coefficient with a desired confidence interval (Olivoto et al., 2018) as follows n = [ CI_w0.45304^r 2.25152 ]^ - 0.50089
where CI_w is desired confidence interval and r is the correlation coefficient.
References
Olivoto, T., A.D.C. Lucio, V.Q. Souza, M. Nardino, M.I. Diel, B.G. Sari, D.. K. Krysczun, D. Meira, and C. Meier. 2018. Confidence interval width for Pearson's correlation coefficient: a Gaussian-independent estimator based on sample size and strength of association. Agron. J. 110:1-8. doi:10.2134/agronj2016.04.0196
Author
Tiago Olivoto tiagoolivoto@gmail.com
Examples
# \donttest{
corr_ss(r = 0.60, CI = 0.1)
#> -------------------------------------------------
#> Sample size planning for correlation coefficient
#> -------------------------------------------------
#> Level of significance: 5%
#> Correlation coefficient: 0.6
#> 95% half-width CI: 0.1
#> Required sample size: 194
#> -------------------------------------------------
# }