LISTSERV at the University of Georgia
Menubar Imagemap
Home Browse Manage Request Manuals Register
Previous (more recent) messageNext (less recent) messagePrevious (more recent) in topicNext (less recent) in topicPrevious (more recent) by same authorNext (less recent) by same authorPrevious page (January 2001, week 2)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Thu, 11 Jan 2001 07:01:42 -0000
Reply-To:     sashole@bellsouth.net
Sender:       "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:         Paul Dorfman <paul_dorfman@HOTMAIL.COM>
Subject:      Re: Hi there!
Comments: To: Goffmanjr@AOL.COM
Content-Type: text/plain; format=flowed

Jacinto,

As a matter of fact, you do not even need to organize an array for this purpose due to SAS's ability to process lists. If I understand your task correctly (there is a slight inconsistency in the explanation: in the second record, mon_job4 appears to be the greatest, contrary to what you have written), you are in need of finding the maximum amongst mon_job2-mon_job6, compare that maximum to mon_job1, and find which is greater. But it is the same as simply obtaining the maximum of mon_job1-mon_job6. The latter is given by the expression

max_job = max (of mon_job1-mon_job6);

Kind regards, ========================= Paul M. Dorfman Jacksonville, Fl =========================

>From: "'Jacinto (Jack) F. Mendoza'" <Goffmanjr@AOL.COM> > Hello and happy new year! I seem to be at a dilemma with an >array. >Here is the data lay out of certain variables: > >obs mon_job1 mon_job2 mon_job3 mon_job4 mon_job5 mon_job6 >1 3 6 9 12 >2 3 6 12 9... > >How do I create an array in which I can properly compare mon_job1 to > >mon_job2 thru mon_job6? That is, how do I create an array in which I > >can take the highest value of mon_job2 thru mon_job6 and use that >value >(instead of the value utilized in mon_job1). For example, in >obs1 >mon_job4>mon_job1, hence I need to create a variable that takes >hold of >the value of mon_job4; in obs2, I need the value mon_job3 >since it's >greater than mon_job1 (and greater than mon_job1, mon_job2, >and mon_job4). > I hope I'm explaining myself correctly. PLEASE HELP, >THANKS!-jfm

_________________________________________________________________ Get your FREE download of MSN Explorer at http://explorer.msn.com


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