title: Accessing elements within a Corpus
body: <p>I am using the Corpus function to read a file I have created in the below mentioned  directory.</p>
  
  <pre><code>chk &lt;- Corpus(DirSource("C:\\Users\\TCS Profile\\Documents\\R\\Machine Learning Text\\Naive Bayes"))
  </code></pre>
  
  <p>Once the corpus is created, when i validate the variable chk created, i find that the content has been read:</p>
  
  <pre><code> str(chk)
  List of 1
   $ Test.txt:List of 2
    ..$ content: chr [1:7] "Hi Wassup" "How are You" "Hope it Works!!!" "" ...
    ..$ meta   :List of 7
    .. ..$ author       : chr(0) 
    .. ..$ datetimestamp: POSIXlt[1:1], format: "2015-10-14 16:15:17"
    .. ..$ description  : chr(0) 
    .. ..$ heading      : chr(0) 
    .. ..$ id           : chr "Test.txt"
    .. ..$ language     : chr "en"
    .. ..$ origin       : chr(0) 
    .. ..- attr(*, "class")= chr "TextDocumentMeta"
    ..- attr(*, "class")= chr [1:2] "PlainTextDocument" "TextDocument"
   - attr(*, "class")= chr [1:2] "VCorpus" "Corpus"
  </code></pre>
  
  <p>The problem is I am unable to access a specific value within the content, let's say the 3rd element. (Hope it Works!!)
  I have tried using the following code:</p>
  
  <pre><code>chk[[1]][1,3]
  </code></pre>
  
  <blockquote>
    <p>Error in chk[[1]][1, 3] : incorrect number of dimensions</p>
  </blockquote>
  
  <p>Can anyone please tell me how can I access the corresponding element and why such an error is coming for the above type of access?</p>