str_trim: Trim leading spaces, trailing spaces or both.

View source: R/string.R

str_trimR Documentation

Trim leading spaces, trailing spaces or both.

Description

Trim leading spaces, trailing spaces or both.

Usage

str_trim(x, where = c("leading", "trailing", "both")[3], replace_with = "")

Arguments

x

character vector

where

character of either 'leading', 'trailing', 'both' (default)

replace_with

character, by default ""

Value

trimmed character vector of same length as the input


btupper/rscripting documentation built on Oct. 18, 2022, 6:47 p.m.