Hello,
Try the following.
x <- "Braund, Mr. Owen Harris"
sub("^.*, (M[[:alpha:]]*)\\..*$", "\\1", x)
Hope this helps,
Rui Barradas
Em 16-02-2014 12:50, Gianluca Rossi escreveu:
Hello,
I have a vector containing some names. I want to extract the title on
every row, basically everything betw
Hello,
I have a vector containing some names. I want to extract the title on
every row, basically everything between the ", " (included the white
space) and "."
> head(combi$Name)
[1] "Braund, Mr. Owen Harris"
[2] "Cumings, Mrs. John Bradley (Florence Briggs Thayer)"
[3] "Heik
2 matches
Mail list logo