I have a cell array A and a cell array B and want to re-order info in A according to B.
Show older comments
I have a cell array A {1:2,1:23} and a cell array B {1,1:300}. B is the reference standard to re-order A. The cell array A {1,1:23} contains a small subset of uid information of B {1,1:300}, but in a random order. I also have geometrical information in A {2, 1:23} corresponding to A {2, 1:23} but, not included in B at all. What I want to do is to create a cell array or matrix C, with all information of A {1,1:23} contained in B, re-ordered. The re-ordering needs to follow the sequence of appearance of elements A in B (hence, the exact order the elements A appear in B sequentially re-ordered). I then need to re-order A {2,1:23} in the same way (via indexing?). Any ideas would be very much appreciated! I attach A and B.
Accepted Answer
More Answers (0)
Categories
Find more on Multidimensional Arrays in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!