I'd like to see a button on the help pane, or a keyboard shortcut, to run the examples for the active help page. That is the more important and easily implemented part.
I'd like it even better if the results appeared at the bottom of the help page, or in a new window, rather than in the console.
I agree that would be a convenience over cut-and-paste; however, the hard part is still going to be understanding the output and which parts of the input got you there, sadly. Inevitable part of a functional language with many possible arguments, not all of which are necessarily familiar.
In newer versions of RStudio (i think v 1.1.x and higher - although not entirely sure the first version it appeared) you are able to run the code in help files by highlighting it and then using the keyboard shortcut Ctrl + Enter
@andrewH, I'm curious about this bit — do you just find it visually disruptive to have examples run in the console? Or do you mean that you'd prefer that they run in a completely independent R session?
For the latter (running an example without messing with my current environment/session), the reprex package and especially its Add-in can be helpful.
Cons:
You have to copy the example to a new script file and add the right library() statements
You still get reprex::reprex() output in the console
Pros:
Stuff created by the example stays out of your workspace/session
Example code and results all appear together in the RStudio Viewer pane
Also wanted to point out this collection of ideas from the github issue tracker: