format_value {rempsyc} | R Documentation |
Easily format p or r values
Description
Easily format p or r values. Note: converts to character class for use in figures or manuscripts to accommodate e.g., "< .001".
Usage
format_value(value, type = "d", ...)
format_p(
p,
precision = 0.001,
prefix = NULL,
suffix = NULL,
sign = FALSE,
stars = FALSE
)
format_r(r, precision = 0.01)
format_d(d, precision = 0.01)
Arguments
value |
Value to be formatted, when using the generic |
type |
Specify r or p value. |
... |
To specify precision level, if necessary, when using the
generic |
p |
p value to format. |
precision |
Level of precision desired, if necessary. |
prefix |
To add a prefix before the value. |
suffix |
To add a suffix after the value. |
sign |
Logical. Whether to add an equal sign for p values higher or equal to .001. |
stars |
Logical. Whether to add asterisks for significant p values. |
r |
r value to format. |
d |
d value to format. |
Details
For the easystats equivalent, see:
insight::format_value()
.
Value
A formatted p, r, or d value.
Examples
format_value(0.00041231, "p")
format_value(0.00041231, "r")
format_value(1.341231, "d")
format_p(0.0041231)
format_p(0.00041231)
format_r(0.41231)
format_r(0.041231)
format_d(1.341231)
format_d(0.341231)
[Package rempsyc version 0.1.8 Index]