title: using knitr/rmarkdown to produce outputs in multiple natural languages (from a data.frame)
body: <p>I am trying to produce a document in <code>rmarkdown</code> that can produce outputs in multiple (natural) languages, it should extract the text in one of the translations from a <code>data.frame</code>. </p>
  
  <p>The <code>data.frame</code> should contain a column for each language and translations of the same text on each row, e.g.</p>
  
  <pre><code>EN &lt;- c('title', 'author', 'a sentence')
  FR &lt;- c('titre', 'auteur', 'une phrase')
  translation &lt;- data.frame(EN, FR, stringsAsFactors = FALSE)
  </code></pre>
  
  <p>It should be possible to format the text extracted, e.g. </p>
  
  <pre><code># [desired code here]
  </code></pre>
  
  <p>Should produce and rmarkdown title.</p>
  
  <p><strong>EDIT</strong>: Ideally we would be able to specify the language in the YAML front-matter</p>