Summary
This chapter brought in many tools for working with strings. To refresh our memory, string are textual information. Like any other data, text can carry a lot of information and good insights if we have the right tools to extract it. That was exactly what we did in the last few pages.
We learned about the main functions from the stringr
library, which is part of the tidyverse package. The benefit of learning how to use libraries from tidyverse is easy coding and its adherence to the tidy concept, helping you transform your data and prepare it for modeling. We saw that stringr
functions start with the str_
prefix followed by a task identifier, making it easier to learn and remember the coding.
Next, we covered the most used regexp patterns, which are strings for creating highly customized textual patterns for many different analysis tasks.
Finally, we learned how to use a combination of stringr
functions plus regexps and some base R functions, to create data summaries...