title: Why setting working directory in R Notebook doesn't change working directory in console?
body: <p><a href="http://rmarkdown.rstudio.com/r_notebooks.html#executing_code" rel="noreferrer">Rstudio states that:</a></p>
  
  <blockquote>
    <p>the current working directory inside a notebook chunk is always the
    directory containing the notebook .Rmd file.</p>
  </blockquote>
  
  <p>Understood. But if within a notebook we <code>setwd()</code> to something (either to "the directory containing the notebook .Rmd file" or elsewhere, doesn't matter), this doesn't set the working directory in the console, only in the notebook.</p>
  
  <p>The reverse is also true, setting working directory in the console doesn't change the working directory in the notebook — though this is somewhat explained by the above.</p>
  
  <p>The only way to set working directory both in the console and a notebook seems to be to run the same <code>setwd()</code> call in both console and notebook.</p>
  
  <p>Why?</p>
  
  <p>Is there any way to streamline this so that the working directory is automatically the same for both notbook and console, once a <code>setwd()</code> call is made, rather than confusingly having two 'parallel' working directories?</p>
  
  <p>One assumes one is not alone in working from notebooks, but doing the 'dirty work' and quick checks that one has no plan to keep in the console. This working directory behaviour is therefore quite frustrating.</p>