Jiho.han, > I wonder if there's a way to replicate SAS rank procedure where it ranks a > variable by a certain number of groups. For example, it's very easy to > calculate quintile rank in SAS, but I couldn't find the similar function in > R. > > Does anyone know how to do this?
There are some functions you can try: rank(), order() or sort(). Actually, I didn't understand well your problem. > PLEASE do read the posting guide http://www.R-project.org/posting-guide.html > and provide commented, minimal, self-contained, reproducible code. It can be a simple SAS code just to let us help you more. Rogerio ______________________________________________ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.