From 45974b57535e3523ecdc03fdc26e01ef99ca6165 Mon Sep 17 00:00:00 2001 From: Kaustubh Patil Date: Thu, 25 Mar 2021 14:04:56 +0100 Subject: [PATCH] fix invalid check for real-values nsga2 --- R/nsga2.R | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/R/nsga2.R b/R/nsga2.R index 0af0a30..f277b00 100644 --- a/R/nsga2.R +++ b/R/nsga2.R @@ -222,8 +222,8 @@ nsga2 <- function(type = c("binary", "real-valued", "permutation"), nBits <- NA if (length(lower) != length(upper)) stop("lower and upper must be vector of the same length") - if ((length(lower) != nObj) & (length(upper) != nObj)) - stop("The lower and upper limits must be vector of the same number of objectives") + #if ((length(lower) != nObj) & (length(upper) != nObj)) + # stop("The lower and upper limits must be vector of the same number of objectives") nvars <- length(upper) if (is.null(names) & !is.null(lnames)) names <- lnames if (is.null(names) & !is.null(unames)) names <- unames