I need to get the maximum of a variable in a nested list. For a certain station number "s" and a certain member "m", mylist[[s]][[m]] are of the form:

station date.time        member  bias
6019    2011-08-06 12:00 mbr003  86
6019    2011-08-06 13:00 mbr003  34

For each station, I need to get the maximum of bias of all members. For s = 3, I managed to do it through:

library(plyr)
var1 <- mylist[[3]]
var2 <- lapply(var1, `[`, 4)
var3 <- lapply(var2, .fun = max)
max.value <- max(var3)

Is there a way of avoiding the column number "4" in the second line and using the variable name $bias in lapply or a better way of doing it?

r
Edit
Report