Is there a way in R to pause script execution until a file is created? I would like to preload R in advance in order to reduce the execution time when creating the input file.
If you want to keep this in R, you can try the following code:
while (!file.exists(your.file.name)) { Sys.sleep(1) }
A shorter duration of sleep will be more likely to be polled, but may be slightly more intense.