Did you know that you can navigate the posts by swiping left and right?

grep in R

06 May 2016 . category: R . Comments
#pattern matching #R

I just keep finding cool stuff in R. I hope you know about grep in unix. If not, google it. grep is a wonderful tool to find a pattern in the contents of a file.

I just looked around for like 5 second and found that R also has a method called grep; it actually has many derivatives of grep. You can use this method to match a pattern on a string of text and get the row index matching that pattern. Cool!

I will try a bit more and will post some code using this in a while…


Me

Sergio Vargas. Assistant professor at the LMU München. Working with octocorals, sponges and cyanobacteria.