LISTSERV at the University of Georgia
Menubar Imagemap
Home Browse Manage Request Manuals Register
Previous messageNext messagePrevious in topicNext in topicPrevious by same authorNext by same authorPrevious page (September 2007, week 1)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:   Wed, 5 Sep 2007 08:48:14 -0700
Reply-To:   cherub <cherub2life@YAHOO.COM>
Sender:   "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:   cherub <cherub2life@YAHOO.COM>
Subject:   SAS coding help
Content-Type:   text/plain; charset=iso-8859-1

Hi,

I need some help for my coding. Now I have a dataset sorted by date and id(see below)

Id date key 12 12May2001 1254 12 13Dec2004 1204 12 15Jan2005 1002 15 15Apr1998 0998 15 05Feb2000 0147 ......

I need to generate a new variable which can give the rank for date by id, such as

Id date Key rank 12 12May2001 1254 1 12 13Dec2004 1204 2 12 15Jan2005 1002 3 15 15Apr1998 0998 1 15 05Feb2000 0147 2 ......

Does somebody know how to generate this variable?

Thanks

Yanyan

--------------------------------- Looking for a deal? Find great prices on flights and hotels with Yahoo! FareChase.


Back to: Top of message | Previous page | Main SAS-L page