Hello,
Suppose I have a matrix A as follows
A = [1 2 3; 4 5 6; 7 8 9]
and an array with indexes:
i = [1 2 2]
each element in i denotes a column in a row, i.e. i(1) –> 1st column of first row in A
Is it possible (without a for loop) to set for each row, columns from 1 to the correspondent index in i to a certain value, say 0?
Thank you for your time
Best Answer