pad2longest: Pad a string to the longest width of the strings.

View source: R/utils_pad.R

pad2longestR Documentation

Pad a string to the longest width of the strings.

Description

Pad a string to the longest width of the strings.

Usage

pad2longest(string, side = "right", pad = " ")

Arguments

string

Strings.

side

Side on which padding character is added (left, right or both).

pad

Single padding character (default is spaces).

Value

    Strings.

Examples

x <- c("a", "ab", "abc")
pad2longest(x, side = "right", pad = " ")


ecan documentation built on July 9, 2023, 5:13 p.m.