[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
## Re: Extracting segents of data from array

**From**: |
Louis Ciotti |

**Subject**: |
Re: Extracting segents of data from array |

**Date**: |
Thu, 6 Jan 2011 14:09:41 -0500 |

Follow up to this question... Is it possible to locate the row and
column with the maximum value of a m x n matrix?
On Mon, Jan 3, 2011 at 3:38 PM, Ben Abbott <address@hidden> wrote:
>* On Jan 3, 2011, at 3:23 PM, Louis Ciotti wrote:*
>
>*> Thanks for the quick and accurate response. Now another question. Is*
>*> there a way to identify the rows that are greater than a given value?*
>*>*
>*> Say I want to know all the row numbers greater than 0.25.*
>
>* Assuming your array has multiple rows and one column ...*
>
>* m = find (a > 0.25);*
>
>* If your array has multiple rows and columns, the rows with one or more *
>* elements larger than 0.25 ...*
>
>* m = find (any (a.' > 0.25));*
>
>* If you want the rows and columns for elements larger than 0.25 ...*
>
>* [m, n] = find (a > 0.25);*
>
>* Ben*
>
>