R/hasSeg.R

Defines functions hasSeg

Documented in hasSeg

hasSeg <-
function(CPvector, start, end){
  if(!(start %in% CPvector & end %in% CPvector)) return(FALSE)
  else {
    if((end != start+1) & (sum((start+1):(end-1) %in% CPvector)!=0)) return(FALSE)
    else return(TRUE)
  }
}

Try the ARTIVA package in your browser

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

ARTIVA documentation built on May 1, 2019, 6:31 p.m.