title: How to pause a running program in R studio?
body: <p>I want to run a program which uses genetic algorithm. I'm processing 50 generations of 10,000 rules for 2000 iterations (stopping criteria). So, the time it takes is a lot. For the case of 4 generation and 4 iterations it took 30 minutes. How can I pause the running of such program at a certain iteration without losing the output of the algorithm before that iteration?
  Can I put the result in stack ( like what we do in assembly language) or does R studio provide an option for my problem?
  Any suggestion would be appreciated too.</p>