Data:
df <- data.frame("y"= c(rep(100,10), rep(103,10)), "x" = c(rep(1,8),2,2,rep(4,5),7,7, rep(4,3)) )
For each value of y, we expect a unique value of x. But in data, we have a couple of unwanted values. Based on mode, we can find the corresponding value of x for each value of y.
Can we identify the row numbers where there is unwanted pairing ?
Expected output: 9, 10, 16, 17