title: how to execute .r files in windows
body: <p>Below is the code in a <code>.r</code> file. I want to execute this from a Windows command prompt, but how?</p>
  
  <pre><code>library(coda)
  a &lt;- read.coda("CODAchain1.txt","CODAindex.txt")
  out &lt;- capture.output(summary(a)) 
  cat(out,file="out.txt",sep="\n",append=FALSE) 
  </code></pre>