R/Even.R

Defines functions Even

Documented in Even

Even <- function(x){
  result <- vector()
  if(!is.numeric(x)){
    cat("Even only works on numbers")
    stop()
  }
  for(i in 1:length(x)){
    if(x[i]/2 == round(x[i]/2)){
      result[i] <- T
    }else{
      result[i] <- F
    }
  }
  return(result)
}

Try the evobiR package in your browser

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

evobiR documentation built on May 2, 2019, 5:40 a.m.