Answers for "check if column contains string in vector r"

0

check if column contains string in vector r

v <- c('a','b','c','e')

'b' %in% v
## returns TRUE

match('b',v)
## returns the first location of 'b', in this case: 2
Posted by: Guest on May-28-2020

Code answers related to "check if column contains string in vector r"

Browse Popular Code Answers by Language