title: tm_map error message in R
body: <p>I can create a corpus in R but when I try to apply tm_map functions to it I get the following error message:</p>
  
  <p>Error in UseMethod("as.PlainTextDocument", x) : 
    no applicable method for 'as.PlainTextDocument' applied to an object of class "c('PlainTextDocument', 'TextDocument', 'character')"</p>
  
  <p>The code up to that point is:</p>
  
  <pre><code>setwd("C:/…/Documents/TextMining")
  webtextGoogle &lt;- GoogleNewsSource("Greek shipping")
  GreekShippingContent &lt;- WebCorpus(GoogleNewsSource("Greek shipping"))
  writeCorpus(GreekShippingContent, "C:/…/Documents/TextMining", filenames = paste(seq_along(GreekShippingContent), ".txt", sep=""))
  GreekShippingContent0 &lt;- Corpus(DirSource("C:/…/Documents/TextMining"), list(reader = readPlain))
  GreekShippingContent2 &lt;- tm_map(GreekShippingContent0, as.PlainTextDocument)
  </code></pre>
  
  <p>I have looked in the documentation and explanations of what this means in related contexts but I cannot understand what to do (not a developer).  Can anyone correct the code?  I have learned a lot by example.  Thanks.</p>