"Thomas " <firstname.lastname@example.org> wrote in message <email@example.com>... > This code essentially gives me the output I wanted, matched rows concatenated to form an m x 4 array: > OUTPUT > D = > > 2 4 2 4 > 3 1 3 1 > 5 7 5 7 > 8 4 8 4 > This output is fine though it runs a bit slow on big datasets.
As I suspect, D is equal to [C C] or repmat(C,[1 2]). Why bother with ia, ib????
I don't understand the rest of your post, with x, xy, ind etc...
If you want to reconstruct D from A, and B, it's just [A(ia,:) B(ib,:)], but again it's the same as [C C].