Take the 2-minute tour ×

Does anyone know how to stop program execution without exiting the R console? I could just call q("no") but am actually looking for something similar to a throws statement to stop the execution, but leave the console active. Return?

share|improve this question
What... those aren't constructive comments. –  Kevin Jul 10 '12 at 4:25
Install the fortunes package. Both of those will reveal witty comments from R-help mailing list referencing stop(), which is the answer you accepted. Not un-constructive, just overly witty. –  joran Jul 10 '12 at 4:45

1 Answer 1

up vote 5 down vote accepted

You can use the stop function:

share|improve this answer
Thank you David Robinson –  Kevin Jul 10 '12 at 4:19

Your Answer


