Learn R Programming

papaja (version 0.1.2)

beautify_terms: Prettify Term Names

Description

Remove parentheses, replace colons with $\times$. Useful to prettify term names in apa_print() tables.

Usage

beautify_terms(x, ...)

# S3 method for character beautify_terms(x, standardized = FALSE, retain_period = FALSE, ...)

# S3 method for numeric beautify_terms(x, standardized = FALSE, ...)

# S3 method for factor beautify_terms(x, standardized = FALSE, ...)

# S3 method for data.frame beautify_terms(x, ...)

Value

A character vector or data.frame (if x is a data.frame) containing term names modified for nicer printing.

Arguments

x

Character. Vector of term names to be prettified.

...

Additional arguments passed to apa_num(), for numeric values in x, ignored otherwise.

standardized

Logical. If TRUE, the name of the function scale() will be removed from term names.

retain_period

Logical. If TRUE, any periods in term names will be retained, otherwise they will be replaced by a space.

Examples

Run this code
beautify_terms("a:b")
beautify_terms("scale(x)", standardized = TRUE)
beautify_terms("snake_case")

Run the code above in your browser using DataLab