Suggestion for a new feature in RStudio: "Toggle" lines of code to run in development mode.
Use Case: I am developing code and have many diagnostic type commands within the code - that check out data, say using head(), glimpse(), or that produces interim graphs - so that I can check out that my code is running correctly. Perhaps some of these commands take a while to run.
But, if I am generally happy with the code and want to run whole blocks of code, say from line 1 to my current line (say using ctrl+alt+B), my diagnostic commands throughout the code will run again, slowing down the process. I could go back and comment out all my diagnostics, but then if I want them back I have to uncomment them.
Would there be a way to click/toggle a button in RStudio that would skip over designated (diagnostic) code? Perhaps the diagnostic code lines could be prefixed with "*" so that RStudio can know which lines to skip when the button is depressed.