vsetequal | R Documentation |
Unlike the base::setequal
function, if the vectors have repeated elements in common, the count of these elements is checked. As a result, vectors of different lengths will never be "equal."
vsetequal(x, y, multiple = TRUE)
k
x |
A vector or an object which can be coerced to a vector |
y |
A vector or an object which can be coerced to a vector |
multiple |
Should repeated "multiple" items be returned? Default is |
A logical value indicating equality or inequality. If multiple=FALSE
is set, both input vectors are reduced to unique values before checking for equality.
Carl Witthoft
setequal
, the CRAN package sets
x <- c(1:5,3,3,3,2,NA,NA)
y<- c(1:5,4,3,NA)
vsetequal(x,y)
vsetequal(x,y,multiple=FALSE)
setequal(x,y) #same as previous line
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.