I have a list of data frames:

```
data1 <-
data.frame(
    ID = c(1, 1, 1, 1),
    Name1 = c(3, 2, 3, 2),
    Name2 = c(4, 5, 4, 5),
    Name3 = c(6, 7, 6, 7),
    Name4 = c(8, 9, 8, 9))
data2 <-
data.frame(
    ID = c(2, 2, 2),
    Name4 = c(7, 3, 3),
    Name2 = c(3, 1, 1),
    Name3 = c(2, 2, 2),
    Name1 = c(1, 1, 1))
data3 <-
data.frame(
    ID = c(3, 3, 3, 3, 3, 3),
    Name3 = c(6, 6, 6, 6, 6, 6),
    Name1 = c(2, 2, 2, 2, 2, 2),
    Name4 = c(3, 3, 3, 3, 3, 3),
    Name2 = c(2, 2, 2, 2, 2, 2))
data4 <-
data.frame(
    ID = c(4, 4, 4, 4),
    Name2 = c(5, 7, 7, 5),
    Name3 = c(1, 1, 1, 1),
    Name1 = c(9, 1, 9, 1),
    Name4 = c(3, 3, 3, 3))

list_data <- list(data1, data2, data3, data4)

```

I also have a list with an equal number of entries, each entry contains a vector of row positions in list\_data:

```
rows1 <- c(1, 4)
rows2 <- c(1)
rows3 <- c(1, 3, 6)
rows4 <- c(2, 3)

list_rows <- list(rows1, rows2, rows3, rows4)

```

How can I subset each dataframe in `list_data` using the corresponding vector of row positions in `list_rows`?