Description Usage Arguments Value Examples
Replicates '==' behavior, but returns F instead of NA when making comparisons of <exists> == NA. NA == NA still returns missing when comparing equal length vectors.
Left and Right sides must be same length, or one of them length 1.
Equal length vectors will return vector of point-wise comparisons between the two
If left or right is length 1, it compares it to the entire other vector, returning a vector of logicals comparing to each place.
1  | left %==% right
 | 
left | 
 Left side of operator  | 
right | 
 right side of operator  | 
vector of logicals
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17  | colors = c("red","blue")
Col_Samp1 = sample(c(colors,NA), size = 10, replace = T, prob = c(.5,.2,.3))
Col_Samp2 = sample(c(colors,NA), size = 10, replace = T, prob = c(.5,.2,.3))
View(t(rbind(Col_Samp1,Col_Samp2,
       Col_Samp1  ==  Col_Samp2,
       Col_Samp1 %==% Col_Samp2)))
View(t(rbind(Col_Samp1,Col_Samp2,
       'red'  ==  Col_Samp1,
       'red' %==% Col_Samp1)))
T  ==  NA
T %==% NA
NA  ==  NA
NA %==% NA
 | 
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.