e_pval_stars: Return star symbols for ranges between a set of p-values, or...

View source: R/e_pval_stars.R

e_pval_starsR Documentation

Return star symbols for ranges between a set of p-values, or any set of numbers

Description

Default text for caption: "p-value stars: (blank): not sig.; -: p > 0.10; *: p <= 0.05; **: p <= 0.01; ***: p <= 0.001; ****: p <= 0.0001"

Usage

e_pval_stars(
  p_values = NULL,
  cutpoints = c(0, 1e-04, 0.001, 0.01, 0.05, 0.1, 1),
  symbols = c("****", "***", "**", "*", "-", " ")
)

Arguments

p_values

list of p-values

cutpoints

list of p-value cutpoints, should include 0 and 1 at extremes

symbols

list of symbols with length one fewer than cutpoints to indicate which two cutpoints the p-value was between

Value

a list of symbols of the same length as p_values

Examples

e_pval_stars(c(0.049, 0.050, 0.051, NA))

erikerhardt/erikmisc documentation built on April 17, 2025, 10:48 a.m.