title: Indexing nested lists in R
body: <p>I have a nested list:</p>
  
  <pre><code>&gt;str(myNestedList)
  List of 9
  $ : num [1:33, 1:4] 42.84 36.49 12.17 27.64 4.33 ...
  $ : num [1, 1:4] 61 NA NA NA
  $ : num [1:27, 1:4] 6.63 NA NA NA 1.75 ...
  $ : num [1:17, 1:4] 63.6 135.2 NA 31.9 NA ...
  $ : num [1:5, 1:4] NA 19.6 42.4 22.3 41.7 ...
  $ : num [1:45, 1:4] NA 20.3 12.1 78.4 343.9 ...
  $ : num [1:13, 1:4] 47.1 14.3 130.6 12.2 28.2 ...
  $ : num [1, 1:4] 315 NA NA NA
  $ : num [1:65, 1:4] 21.16 5.31 13.1 3.23 25.77 ...
  </code></pre>
  
  <p>I want to index the nested list using the last dimension like so: </p>
  
  <pre><code>myOuputList &lt;- list()
  for(i in 1:4) {
    myOutputList[[i]] &lt;- myFunction(myNestedList[[,]][,i])
  }
  </code></pre>
  
  <p>Would a kind soul please explain why this does not work and how to fix it?</p>
  
  <p>Cheers,</p>