bstr_count: Count the number of matches in a bstr object

Description Usage Arguments Examples

View source: R/bstr_count.R

Description

Count the number of matches in a bstr object

Usage

1
bstr_count(bstrobj, pattern = "")

Arguments

bstrobj

bstr class object or character vector

pattern

regex pattern

Examples

1
2
3
bstr_count(c("apple", "banana"))
bstr_count(c("apple", "banana"), "a")
bstr_count(c("apple", "banana"), c("a", "n"))

t-arae/bstringr documentation built on March 18, 2021, 3:08 a.m.