I would like to use the directory of my bat file to run my R script. My R script is in the same directory as my bat file, I tried:
"C:\Program Files\R\R-3.1.2\bin\x64\RScript.exe" "%CD%\script_to_run.R"
but the cmd immediately closes. This works if I specify the entire path of my script instead of using %CD%.
Can I have some help, please?