View source: R/percent_overlap.R
percent_overlap | R Documentation |
The percent_overlap() function is used to calculate the overlap percentage between two numeric vectors. The function uses equation 3 described in chapter 2. The function takes as input two numeric vectors and a desired level of significance and it outputs the percentage overlap between the confidence intervals of population means of the input vectors. If there’s no overlap of the confidence intervals, e.g., the upper bound of the confidence interval of one vector is lower than the lower bound of the confidence interval of the other vector, a negative percent overlap would be displayed.
percent_overlap(x, y, alpha)
x |
a numeric vector |
y |
a numeric vector |
alpha |
level of significance |
percentage overlap between the confidence intervals of the two numeric vectors
## Not run: vecx <- rnorm(100) vecy <- rnorm(100) percent_overlap(vecx, vecy, 0.05) ## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.