R/traitpairstotraits.R

Defines functions traitpairstotraits

Documented in traitpairstotraits

traitpairstotraits <-
function(tp)
# traitpairstotraits() - extract vector of traitnames from vector of traitpairs
{
  t <- rep(" ",length(tp))
  for(i in 1:length(tp)) {
    colon <- which(strsplit(tp[i],"")[[1]] == ":")
    t[i] <- substr(tp[i],1,colon-1)
  }
  tu <- unique(t)
  return(tu)
}

Try the dmm package in your browser

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

dmm documentation built on July 26, 2023, 5:23 p.m.