rfiles/vennchecklogic.R

vennCheckLogic <- function(A_all, B_all, C_all, AandB, AandC, BandC){
    out <- list("isOK" = TRUE)
    
    if (A_all <  AandB){
      out$isOK <- FALSE
      out$proble1 <- "A < (A and B)"
    }
    
    if (B_all <  AandB){
      out$isOK <- FALSE
      out$proble2 <- "B < (A and B)"
    }
    
    if (A_all <  AandC){
      out$isOK <- FALSE
      out$proble3 <- "A < (A and C)"
    }
    
    if (C_all <  AandC){
      out$isOK <- FALSE
      out$proble4 <- "C < (A and C)"
    }
    
    if (B_all <  BandC){
      out$isOK <- FALSE
      out$proble6 <- "B < (B and C)"
    }
    
    if (C_all <  BandC){
      out$isOK <- FALSE
      out$proble6 <- "C < (B and C)"
    }
    
    
  
    return(out)
}
weitingwlin/vennchart documentation built on May 4, 2019, 4:18 a.m.