R/slt.R

Defines functions slt

Documented in slt

slt<-function(ls,slot,index=NULL) {
        ind<-which(names(ls[[1]])==slot);
        if (is.null(index)) sc<-sapply(ls,function(x){x[[ind]]})
        else sc<-sapply(ls,function(x){x[[ind]][index] })
	return(sc)
}

Try the PSEA package in your browser

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

PSEA documentation built on Nov. 8, 2020, 6:54 p.m.