Generate significance stars from p-values using R's standard definitions.
stars_pval(p_value)
p_value | A numeric vector of p-values |
---|
A character vector containing the same number of elements as p-value, with an attribute "legend" providing the conversion pattern.
Mapping from p_value ranges to symbols:
0 - 0.0001: '****'
0.0001 - 0.001: '***'
0.001 - 0.01: '**'
0.01 - 0.05: '*'
0.05 - 1.0: 'ns'
Tiago Olivoto tiagoolivoto@gmail.com
#> [1] "**" "*" "ns" "**" "****" #> attr(,"legend") #> [1] "0 '****' 1e-04 '***' 0.001 '**' 0.01 '*' 0.05 'ns' 1"# }