title: Executable .R file not running, path ignored
body: <p>I'm trying to make <code>helloworld.R</code> run. I have given it executable rights and have added <code>#!/usr/bin/Rscript</code> at the top of the file. (I have also attempted <code>#!/usr/bin/en Rscript</code>). It is a relatively simple file:</p>
  
  <pre><code>#!/usr/bin/Rscript
  
  x &lt;- rnorm(100)
  df &lt;- data.frame(x = x)
  write.csv(df, "sim_data.csv")
  </code></pre>
  
  <p>However, any attempt to run the file has been met with the following error</p>
  
  <pre><code>ARGUMENT '/home/path/to/file/helloworld.R' __ignored__
  
  R version 3.4.3 (2017-11-30) -- "Kite-Eating Tree"
  Copyright (C) 2017 The R Foundation for Statistical Computing
  Platform: x86_64-pc-linux-gnu (64-bit)
  
  (...)
  </code></pre>
  
  <p>Surprisingly, renaming the file to <code>helloworld.py</code> lets it run just fine (and outputs <code>sim_data.csv</code> with its expected content), but this seems hacky, so I was wondering if there was a better solution.</p>