help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Abs highest(extreme) value in a matrix with +ve & -ve elements


From: Andy Buckle
Subject: Re: Abs highest(extreme) value in a matrix with +ve & -ve elements
Date: Mon, 23 Jan 2012 12:39:49 +0000

On 23 January 2012 12:27, Penfold <address@hidden> wrote:
> What is wrong with using min()?

Very good point!

Also you can do this

a=round((rand(3)-0.5)*10)
[val_pos i_pos]=max(a)
[val_neg i_neg]=min(a)

to do all cols at once. Also, use the DIM arg of max and min to do all
rows at once.

-- 
/* andy buckle */


reply via email to

[Prev in Thread] Current Thread [Next in Thread]