help-octave
[Top][All Lists]
Advanced

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

Re: Vector approach to row margin frequencies


From: Judd Storrs
Subject: Re: Vector approach to row margin frequencies
Date: Tue, 23 Jun 2009 19:40:09 -0400

On Tue, Jun 23, 2009 at 6:39 PM, ws <address@hidden> wrote:
I would love to now get the row frequencies avoiding a while loop, something
like F=X./S, but that doesn't work (though it seems somehow consistent -- I
realize that we don't recycle vectors in Octave/ Mat* ) ....

Are trying to divide each row by its sum? I think the bsxfun will do this:

bsxfun(@times,X,1./S)

I'm not sure if there is a direct function name for "./". If you can figure that out you can also avoid the separate division.

--judd



reply via email to

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