You already have a list of data frames and cannot do anything further (except row binding them to produce a single data frame). Try reading the subsetting chapter in the Advanced R book.
In brief
R has 3 primary subsetting methods, [
, [[
, and $
. Their behavior depends on what object you use them on. (@
is rarer and used for S4 objects.)
Generally speaking, [
subsetting returns a subset of the same object you had before. For instance, (1:5)[4]
returns a length 1 vector from a length 5 vector. [[
subsetting returns part of the object not necessarily but maybe of the same type as what you had. For vectors, it does the same as [
.
Since lists often contain objects of different types, the difference between [
and [[
can matter a lot. [
subsetting gives you a new list with only the specified elements, while [[
gives you the elements directly. Note that data frames are lists. iris[1]
returns a data frame with only the first column. iris[[1]]
returns a vector, the first object from the iris
data frame.
$
is merely a synonym for [[
that allows autocompletion.
The distinction between [[
and [
can get non-obvious for some objects. For instance, iris[[c(1, 2)]]
does the same as iris[2, 1]
. The first seems to select object 1, then object 2. The second selects row 2 in column 1.