string_compare: Compare string vectors.

string_isblankR Documentation

Compare string vectors.

Description

Compare string vectors.

Usage


string_isblank(s)
string_isupper(s)
string_islower(s)

Arguments

s

A string (character) vector.

Details

The function string_isblank() tests whether a vector consists of only blank characters. Synonyms are s_isblank(), isblank(), and is.blank().

The %like% operator tests whether a pattern match is found in a string.

The functions string_isupper() and string_islower() test whether each element in a string vector is all uppercase or lowercase, respectively. Synonyms are s_fun(), isfun(), and is.fun() (replace "fun" with "upper" or "lower").

Value

Boolean vector.

See Also

https://github.com/robertschnitman/stringops

Examples

string_isblank("         ")
string_isblank("    string     ")

rownames(mtcars) %like% "^M"

string_isupper(c('TEST', 'test', 'tEsT'))
string_islower(c('TEST', 'test', 'tEsT'))


robertschnitman/stringops documentation built on Aug. 15, 2022, 3:46 p.m.