title: System Path vs. Sys.getenv('PATH')
body: <p>This might turn out to be a rather trivial question, but has me baffled for quite some time now. It all started when I installed the universal document converter <code>pandoc</code> and added it to  my path. So when I do <code>echo $PATH</code> on the default terminal on my Mac OS X, it shows <code>pandoc</code> and I am able to execute it.</p>
  
  <p>However, when I tried invoking the same in an R session using <code>system(pandoc --version)</code>, it could not recognize <code>pandoc</code>. Further checking revealed that <code>system('echo $PATH')</code> does not return the same path that I got on the terminal.</p>
  
  <p>Can anyone help me with what is going on? I like to do all my work on <code>RStudio</code>, and hence would prefer if I can use <code>pandoc</code> directly from within. Hence the need to figure this out.</p>