E.4 Resources

Regular expressions are powerful tools, of course, but also a slippery slope on which computer-friendly folks can easily spend more time than anyone must know. Consider the clip in Figure E.4 a friendly warning:

Yet another use of regular expressions: Creating new problems to be solved by regular expressions… (from xkcd).

Figure E.4: Yet another use of regular expressions: Creating new problems to be solved by regular expressions… (from xkcd).

Consult the following links for additional resources on regular expressions.

E.4.1 Background

For a proper definition, the historical background, and some key references on regular expressions:

E.4.2 Learning and training

Many online sites offer tutorials and ways of trying out your regex skills:

E.4.3 References

For using regular expressions in R:

  • Evaluating ?base::regex provides documentation on Regular Expressions as used in R.

  • See the back page of the RStudio cheatsheet on the stringr package (Wickham, 2019b) and the cheatsheet on Basic Regular Expressions in R (contributed by Ian Kopacka):

Basic regular expressions in R (by Ian Kopacka)<br> available at [RStudio cheatsheets](https://www.rstudio.com/resources/cheatsheets/).

Figure E.5: Basic regular expressions in R (by Ian Kopacka)
available at RStudio cheatsheets.


ds4psy

[70_regex.Rmd updated on 2022-07-15 18:32:01 by hn.]

References

Wickham, H. (2019b). stringr: Simple, consistent wrappers for common string operations. Retrieved from https://CRAN.R-project.org/package=stringr