The Math Forum

Search All of the Math Forum:

Views expressed in these public forums are not endorsed by NCTM or The Math Forum.

Math Forum » Discussions » Software » comp.soft-sys.matlab

Notice: We are no longer accepting new posts, but the forums will continue to be readable.

Topic: how apply bsxfun to all the rows of a matrix?
Replies: 2   Last Post: Dec 27, 2011 7:00 PM

Advanced Search

Back to Topic List Back to Topic List Jump to Tree View Jump to Tree View   Messages: [ Previous | Next ]

Posts: 17
Registered: 2/28/07
Re: how apply bsxfun to all the rows of a matrix?
Posted: Dec 27, 2011 7:00 PM
  Click to see the message monospaced in plain text Plain Text   Click to reply to this topic Reply

On Dec 27, 3:30 pm, "Matt J " <mattjacREM...@THISieee.spam> wrote:
> Aseman <> wrote in message <>...

> > How could I repeat the above for all the rows of test, without any
> > loop in the code?

> rowDiff=bsxfun(@minus, test, reshape(test.',[1,size(test.')]))

Thanks Matt!
I should have learned from the solution you provided to my previous

Point your RSS reader here for a feed of the latest messages in this topic.

[Privacy Policy] [Terms of Use]

© The Math Forum at NCTM 1994-2018. All Rights Reserved.