R/are.tips.consecutive.R

## This code is part of the ips package
## © C. Heibl 2014

are.tips.consecutive <- function(phy){
  canonical <- seq_along(phy$tip.label)
  given <- phy$edge[, 2][phy$edge[, 2] %in% canonical]
  given <- as.integer(given)
  if ( !identical(canonical, given) ) 
    stop("tips are not numbered consecutively.",
         " Type '?fixNodes' for help.")
}

Try the ips package in your browser

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

ips documentation built on July 4, 2019, 5:04 p.m.