Learn R Programming

stringstatic (version 0.1.2)

str_trim: Remove whitespace

Description

Dependency-free drop-in alternative for stringr::str_trim().

Usage

str_trim(string, side = c("both", "left", "right"))

Value

A character vector the same length as string.

Arguments

string

Input vector. Either a character vector, or something coercible to one.

side

Side on which to remove whitespace: "left", "right", or "both", the default.