Simple tricks for Debugging Pipes (within magrittr, base R or ggplot2)
You know it, I’m sure: You are developing a data transformation using lots of pipes. Then you need to remove one or more lines. You do this using comments.
So far so good. But if it’s the last line you want to remove a simple comment will produce an error because of the trailing pipe symbol at the end of the second to last line.
Here’s a solution: