strs_find
locates the first occurrence of a specified substring within each
element of a character vector. This function is analogous to Python's
str.find()
method.
Value
An integer vector of the same length as string
, with each element
representing the starting position of the first occurrence of substring
in
the corresponding element of string
. If the substring is not found, the
function returns NA for that element.