corr_ss: Sample size planning for a desired Pearson's correlation...

View source: R/corr_ss.R

corr_ssR Documentation

Sample size planning for a desired Pearson's correlation confidence interval

Description

[Stable]

Find the required (sufficient) sample size for computing a Pearson correlation coefficient with a desired confidence interval (Olivoto et al., 2018) as follows \loadmathjax \mjsdeqnn = \left[ \fracCI_w0.45304^r \times 2.25152 \right]^\rm - 0\rm.50089

where \mjseqnCI_w is desired confidence interval and \mjseqnr is the correlation coefficient.

Usage

corr_ss(r, CI, verbose = TRUE)

Arguments

r

The magnitude of the correlation coefficient.

CI

The half-width for confidence interval at p < 0.05.

verbose

Logical argument. If verbose = FALSE the code is run silently.

Author(s)

Tiago Olivoto tiagoolivoto@gmail.com

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. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.2134/agronj2016.04.0196")}

Examples



corr_ss(r = 0.60, CI = 0.1)




TiagoOlivoto/WAASB documentation built on March 20, 2024, 4:18 p.m.