Bookmark and Share

Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.


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

st: re-sorting by the same variable or storing a permutation vector?


From   László Sándor <[email protected]>
To   [email protected]
Subject   st: re-sorting by the same variable or storing a permutation vector?
Date   Wed, 4 Apr 2012 18:04:27 -0400

Wise peers,

Allow me another question, hopefully of general interest: If I would
need to resort to re-sorting (pun intended) my data multiple times, am
I not better off if I store a permutation vector (after the first
sort, obviously) in a variable and just reapply that? Is there a
faster way to do that than invoking Mata and putting my entire data
over there? (A monster st_view() if there ever was one.) I know Mata
allows fast sorting and permutation vectors (/ subscripting). Is that
the efficient way to go?

http://stata.com/help.cgi?[M-5]+sort()
http://www.stata-journal.com/sjpdf.html?articlenum=pr0028

Thanks for any thoughts on this too,

Laszlo
*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/


© Copyright 1996–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index