photo

Hu


Active since 2013

Followers: 0   Following: 0

Message

Statistics

  • Thankful Level 1

View badges

Feeds

View by

Question


How can I access element with same index from multiple cells
For example, we have a = cell(2,2); a{1} = 1:4; a{2} = 1:4; a{3} = 1:4; a{4} = 1:4; How can we access like ...

11 years ago | 2 answers | 0

2

answers

Question


How to index like A(B(i), i)
For example, A = rand(3, 5); B = [3,2,1,2,3]; and I want C like: for i = 1:size(A, 2) C(i) = A(B(i), i);...

11 years ago | 1 answer | 0

1

answer