title: How to crontab a R-script and append the errors
body: <p>I'm new to <code>Ubuntu</code> and would like to run a daily <code>crontab</code>. I'm running similar job under <code>Windows Command Line</code> but would like to switch to <code>Ubuntu</code>.</p>
  
  <p>My <code>R-Script</code> has an <code>Error-function</code> which prints errors into a separate
  folder everytime a job is done and an error has occured ():</p>
  
  <pre><code> # define error function
   my.error.fun &lt;- function() {
   cat(geterrmessage(), file="/home/network/R/Test.txt", append=TRUE)
  } 
  
  # output error
  options("error"=my.error.fun)
  </code></pre>
  
  <p>Under <code>crontab -e</code> I have determined the following:</p>
  
  <pre><code>00 16 * * * /usr/bin/Rscript /home/R/network/Test.R 2&gt; /home/R/RErrors/Test.txt
  </code></pre>
  
  <p>and the <code>crontab</code>has been saved under <code>/tmp/crontab.2t/crontab</code></p>
  
  <p>where I append the errros inside the R-Script. In contrast to <code>Windows Command Line</code> that concept seems not to work in <code>Ubuntu</code> That seems not to work however. I'm not sure whether thats the correct syntax. There has been no file in the <code>RErrors</code> folder.</p>
  
  <p>May I as for some suggestions?</p>