Well, one way to deal with this issue would be to run KNIME and R together inside of a docker container, so that your instance would be completely (mostly) self contained. Thus, you could, for example, run a cron job to first kill all old docker containers and then boot up a new docker container. This would keep things nice and clean.
Although what I am suggesting may well be overkill for what you want, dockerzing KNIME could have extra benefits for you as well. It would take some work to get everything sorted out, but it is doable. If you know what Docker is, you can check out the thread below for more information, and I am happy to help you further as well. If you have no idea what Docker is but are still interested, you will want to do some reading about the concept first.
https://tech.knime.org/forum/knime-general/knime-in-docker
-Brian Muchmoore