|
michael wrote:
> My problem is this:
>
> I have a large array (say 200 x 6). I would like to:
>
> 1. For all rows greater than x(insert #) in column 1, and all rows
> greater than y(#) in column 2,
>
> (of those which satisfy both conditions)
>
> 2. find the row that has the minimum value for column 3 (of all the rows
> that pass the prev criteria)
>
> 3. For the row selected, read information from columns 4 and 5
200x6 is actually a quite small array, but... :)
In steps, make as much more concise as you desire...
S = A(A(:,1)>x & A(:,2)>y; :);
[mins,idx] = min(S(:,3));
V = [S(idx,4) S(idx,5)];
Salt to suit...
--
|