String Manipulation in R: Fundamentals
In this first lesson of our course on strings, dates and times in R, you'll learn about some new functions as you start working with text data (strings).
In this lesson, we'll go through a detailed review of what strings are and and what we can do with them. Strings are how R represents text, whether we are talking about tweets, electronic medical records or Amazon reviews. Compared to numerical data, text data can be harder to clean and manipulate since there are many, many words. We also can't typically do numerical calculation directly with text; we need to perform some cleaning steps beforehand.
Typical work with strings usually has to do with finding specific words or phrases in a larger paragraph, or counting the number of times it appears in a passage. In this mission, we'll cover techniqyes to accomplish that, including indexing strings, string trimming and padding, splitting strings, string concatenation, regular expressions in R, string replacement, and more!
By the end of this mission, we'll know how to use many of the functions that help us with string manipulation, which will open up our capabilities as a programmer.
- Indexing Strings
- Handling Word Casing
- String Trimming & Padding
- String Splitting
- String Concatenation
- Regular Expressions
- String Detection
- String Replacement
- Next Steps