get specific elements from matrix
Show older comments
Hello,
From an arbitrary matrix I want to extract n elements when I have 2 arrays of lenth n, one containing the row indices and 1 containing the column indices of the desired elements.
For effeciency I would like to avoid a for loop. Is this possible?
Thanks!
Accepted Answer
More Answers (0)
Categories
Find more on Creating and Concatenating Matrices 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!