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: sorting, ranking
Replies: 10   Last Post: Jan 14, 2013 1:25 PM

Advanced Search

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

Posts: 2,357
Registered: 12/6/04
Re: sorting, ranking
Posted: Aug 21, 2009 2:53 PM
  Click to see the message monospaced in plain text Plain Text   Click to reply to this topic Reply

"Wyatt " <hello@hello.com> wrote in message <h6moqe$sqf$1@fred.mathworks.com>...
> that did the trick steve. It just seems to me that
> rank = temp(I)
> should be valid syntax, and is more intuitive than writing
> rank(I) = temp
> perhaps because I'm thinking that if I wanted to arbitrarily pull out values [7 4 9 1] from a vector A I would write
> A([7 4 9 1])
> and it would give me the 7th 4th 9th and 1st values from A in that order.

But to me, this would not be very intuitive at all.

since A([9]) is the same as A(9),
A([9]) should return the 9th index of A (as it does).

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

[Privacy Policy] [Terms of Use]

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