Re: [Tcl-nap-users] Normalize command in nap?
Brought to you by:
dav480,
peter_turner
From: <Har...@cs...> - 2007-03-30 09:26:38
|
<< -----Original Message----- << From: ni...@ma... [mailto:ni...@ma...]=20 << Sent: Thursday, 29 March 2007 19:47 << To: Davies, Harvey (CMAR, Floreat) << Cc: s_...@ya...; tcl...@li... << Subject: Normalize command in nap? << << Hello all, << << I wonder if there's any builtin command to "normalize" a matrix, e.g << divide each element by the sum of its collumn? Following does this for matrix m: "m / sum(m)" If you want to do it for each row then work on transpose as follows: Nap "t =3D transpose(m)" Nap "result =3D transpose(t / sum(t)) << Eigenvectors also? No sorry. I would like more linear algebra functions for such things. << I figure I'd ask before I create loops etc.. Most things can be done without loops. |