Date: Tue, 8 Feb 2005 15:51:31 -0800
Reply-To: "Schwarz, Barry A" <barry.a.schwarz@BOEING.COM>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: "Schwarz, Barry A" <barry.a.schwarz@BOEING.COM>
Subject: Re: comparing fields on the fly
Content-Type: text/plain; charset="us-ascii"
Try an array and a do loop.
-----Original Message-----
From: nyiann [mailto:nwy@UALBERTA.CA]
Sent: Tuesday, February 08, 2005 2:37 PM
To: SAS-L@LISTSERV.UGA.EDU
Subject: comparing fields on the fly
Hi all,
I have data like this:
real sim1 sim2 sim3...
1 3 2 3
4 2 2 1
3 4 7 8
2 3 4 5
1 3 5 4
2 3 4 3
...
I want to cound the number of times, for each record, the number of
times that real is larger than sim. I am doing this by transposing and
then counting, but this seems like the wrong way to do it. There must
be a really easy trick here. Any ideas?
|