Date: Mon, 22 Sep 2003 10:38:19 -0700
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: "David L. Cassell" <cassell.david@EPAMAIL.EPA.GOV>
Subject: Re: Min among variables
Content-type: text/plain; charset=US-ASCII
Pascale.Beaupre@STATCAN.CA wrote [in aprt]:
> data set. I would like to have them ordered chronologically. That is,
> information (variables) concerning the respondents' first child
> second child, and so on... I thought I could create a variable "rank"
> something similar allowing me to order the children by their arrival.
Since you want all the variables sorted (or ranked), instead of your
somewhat misleading subject line of just a 'min among variables', I
suggest you look in the SAS-L archives for posts by Paul Dorfman. He
wrote a complete (and fast) sorting routine for a situation like this,
and his code is designed to be easily incorporated into code. He
also has shown that his code is significantly faster than using
K times to arrange K variables.
David Cassell, CSC
Senior computing specialist