Drexel dragonThe Math ForumDonate to the Math Forum



Search All of the Math Forum:

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


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

Topic: Extracting particular row of a matrix based on specific condition
Replies: 14   Last Post: Jan 3, 2014 10:03 AM

Advanced Search

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

Posts: 8,257
Registered: 6/7/07
Re: Extracting particular row of a matrix based on specific condition
Posted: Jan 2, 2014 2:06 PM
  Click to see the message monospaced in plain text Plain Text   Click to reply to this topic Reply

On 1/2/2014 10:12 AM, Poulomi wrote:
...


> sort is not working but indexing one is working fine. I checked with
> random element, my matrix size is 3822x14.


I think there's a typo in Bruno's w/ the subscript on the index;
otherwise it will produce the same result (oh, wait a minute--it's still
got the problem of there being zero entries I think that have to screen
out).

I believe the above is about optimal--it gets it with only one really
expensive operation; the ismember() call. It's unfortunate there's no
way to pick which of alternate returns one can request or another syntax
to accomplish the same thing w/o the temporary, but that's just "the way
it is"...

--





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

[Privacy Policy] [Terms of Use]

© Drexel University 1994-2014. All Rights Reserved.
The Math Forum is a research and educational enterprise of the Drexel University School of Education.