R/extract.list.R

extract.list <-
function(L, s1, s2=NULL) {
  if(is.null(s2)) {
    sapply(L,function(x) with(x,get(s1)))
  } else {
    sapply(L,function(x) with(with(x,get(s1)),get(s2))  ) 
  }
}

Try the MMMS package in your browser

Any scripts or data that you put into this service are public.

MMMS documentation built on May 2, 2019, 8:25 a.m.