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 (March 2005, week 5)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Tue, 29 Mar 2005 20:28:57 +0000
Reply-To:     toby dunn <tobydunn@HOTMAIL.COM>
Sender:       "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:         toby dunn <tobydunn@HOTMAIL.COM>
Subject:      Re: highest value of multiple variables.
Comments: To: barry.a.schwarz@BOEING.COM
In-Reply-To:  <AD11F90BB3FCF84C965D8F3E3BC66230024BA35F@XCH-NW-26.nw.nos.boeing.com>
Content-Type: text/plain; format=flowed

But then your problem isn't getting the ob with the highest two values its knowing how to get the highest value of a variable and then doing that twice.

Toby Dunn

From: "Schwarz, Barry A" <barry.a.schwarz@BOEING.COM> Reply-To: "Schwarz, Barry A" <barry.a.schwarz@BOEING.COM> To: SAS-L@LISTSERV.UGA.EDU Subject: Re: highest value of multiple variables. Date: Tue, 29 Mar 2005 12:16:10 -0800 MIME-Version: 1.0 Received: from malibu.cc.uga.edu ([128.192.1.103]) by mc10-f3.hotmail.com with Microsoft SMTPSVC(6.0.3790.211); Tue, 29 Mar 2005 12:16:25 -0800 Received: from listserv.cc.uga.edu (128.192.1.75) by malibu.cc.uga.edu (LSMTP for Windows NT v1.1b) with SMTP id <2.00ED3443@malibu.cc.uga.edu>; Tue, 29 Mar 2005 15:16:23 -0500 Received: from LISTSERV.UGA.EDU by LISTSERV.UGA.EDU (LISTSERV-TCP/IP release 1.8d) with spool id 40216 for SAS-L@LISTSERV.UGA.EDU; Tue, 29 Mar 2005 15:16:23 -0500 Received: from blv-smtpout-01.boeing.com (blv-smtpout-01.boeing.com [130.76.32.69]) by listserv.cc.uga.edu (8.12.11/8.12.11) with ESMTP id j2TKGN5N014989 for <SAS-L@LISTSERV.UGA.EDU>; Tue, 29 Mar 2005 15:16:23 -0500 Received: from stl-av-01.boeing.com ([192.76.190.6]) by blv-smtpout-01.boeing.com (8.9.2.MG.10092003/8.8.5-M2) with ESMTP id MAA22400 for <SAS-L@LISTSERV.UGA.EDU>; Tue, 29 Mar 2005 12:16:19 -0800 (PST) Received: from XCH-NWBH-02.nw.nos.boeing.com (localhost [127.0.0.1]) by stl-av-01.boeing.com (8.11.3/8.11.3/MBS-AV-LDAP-01) with ESMTP id j2TKGI715844 for <SAS-L@LISTSERV.UGA.EDU>; Tue, 29 Mar 2005 14:16:18 -0600 (CST) Received: from xch-nw-26.nw.nos.boeing.com ([192.48.4.100]) by XCH-NWBH-02.nw.nos.boeing.com with Microsoft SMTPSVC(6.0.3790.211); Tue, 29 Mar 2005 12:16:14 -0800 X-Message-Info: StaYHEBmGBq8i6AlIdYY4KEQQ2GDQ1X4+koa66fhJM8= X-MimeOLE: Produced By Microsoft Exchange V6.5.7226.0 Content-class: urn:content-classes:message X-MS-Has-Attach: X-MS-TNEF-Correlator: Thread-Topic: highest value of multiple variables. Thread-Index: AcU0l8eVbMwKYyWMRjehBup4sFQ8sAABDLnQ X-OriginalArrivalTime: 29 Mar 2005 20:16:14.0784 (UTC) FILETIME=[286F1C00:01C5349C] X-MIME-Autoconverted: from quoted-printable to 8bit by listserv.cc.uga.edu id j2TKGN5N014990 Return-Path: owner-sas-l@LISTSERV.UGA.EDU

Not if you want the highest value of each. Consider two observations, one with 100 and 1, the other with40 and 40.

-----Original Message----- From: toby dunn [mailto:tobydunn@HOTMAIL.COM] Sent: Tuesday, March 29, 2005 11:45 AM To: SAS-L@LISTSERV.UGA.EDU Subject: Re: highest value of multiple variables.

Nishant,

Without being able to garante that you wont have a highest 'ni' in one obs and a highest 'pi' in anoter observation. In that case you will never get an answer. You can however add the two vars together and get the one ob which has the maximum combined value.

<untested>

Proc sql ; select * from master haveing max(sum(ni , pi)) ; quit ;


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