Hi,
Imagine you have a matrix long the sample size and large the number of sectors in the S&P 500 that contains scores, summarizing the relative attractiveness of sectors. How can I generate another matrix that ranks these scores? To put it differently, I am looking for a function similar to "rank()" in Excel.
Thanks for your help!
Yves
Ranking
Moderators: EViews Gareth, EViews Steve, EViews Moderator, EViews Jason
-
EViews Gareth
- Fe ddaethom, fe welon, fe amcangyfrifon
- Posts: 13603
- Joined: Tue Sep 16, 2008 5:38 pm
Re: Ranking
Not quite sure what you're asking, but probably either the @ranks() function or the @colranks() function.
-
ylongchamp
- Posts: 14
- Joined: Fri Apr 08, 2011 5:03 am
Re: Ranking
@ranks() does not do exaclty what I want. But @colranks() could potentially do that... as long as you explain me how it works and what it does. This function is not described in the help section!
I am looking for a function like @cimax(m1) that returns the index, not the value.
I am looking for a function like @cimax(m1) that returns the index, not the value.
Last edited by ylongchamp on Wed Feb 08, 2012 10:08 am, edited 1 time in total.
-
EViews Gareth
- Fe ddaethom, fe welon, fe amcangyfrifon
- Posts: 13603
- Joined: Tue Sep 16, 2008 5:38 pm
Re: Ranking
It creates a new matrix containing the ranks of each element of the first matrix, but based on column. There is an @rowranks too that does the same thing by rows.
-
ylongchamp
- Posts: 14
- Joined: Fri Apr 08, 2011 5:03 am
Re: Ranking
It is probably the right function, but I still don't know how to use it. Does it work with Eviews 6?
What is the syntax? m2 = @colranks(m1) or @colranks(m1, m2) and what are the options?
m2 = @ranks(m1) works but neither @colranks nor @rowranks seem to follow this syntax.
Why is this function not described in the online help? Are there other functions like this one that are not in the online help?
Thank you Gareth for your help!
Yves
What is the syntax? m2 = @colranks(m1) or @colranks(m1, m2) and what are the options?
m2 = @ranks(m1) works but neither @colranks nor @rowranks seem to follow this syntax.
Why is this function not described in the online help? Are there other functions like this one that are not in the online help?
Thank you Gareth for your help!
Yves
-
EViews Gareth
- Fe ddaethom, fe welon, fe amcangyfrifon
- Posts: 13603
- Joined: Tue Sep 16, 2008 5:38 pm
Re: Ranking
@colranks is not in EViews 6.
It is in EViews 7, but was added after the documentation was written.
It is in EViews 7, but was added after the documentation was written.
Who is online
Users browsing this forum: No registered users and 2 guests
