currently I have to matrixs, and I am trying to return the index values where they match in z? This is what I have currently
x y
matrixloc 0 0
2 1
2 3
2 6
5 5
6 7
4 9
> z
x y
[1,] 2 6
[2,] 3 4
[3,] 5 5
[4,] 2 1
[5,] 2 3
[6,] 6 7
[7,] 4 9
[8,] 6 8
currently the output I am getting is :
match(matrixloc,z)
NA 1 1 1 3 6 7 NA 12 2 6 3 14 15
Any suggestions on how to fix this?