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 (May 2003, week 3)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Thu, 15 May 2003 13:48:53 -0700
Reply-To:     Tim Corn <tim19972003@YAHOO.COM>
Sender:       "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:         Tim Corn <tim19972003@YAHOO.COM>
Subject:      Re: Generate Random Number???
Comments: To: "Droogendyk, Harry" <Harry.Droogendyk@CIBC.com>
In-Reply-To:  <F0161D3F7AC5D411A5BE009027E774D60B91795F@gemmrd-scc013eu.gem.cibc.com>
Content-Type: text/plain; charset=us-ascii

Harry,

I tried your suggestion. But this will lead to the duplicate random number. Thanks again for your advice!

Tim

"Droogendyk, Harry" <Harry.Droogendyk@CIBC.com> wrote: random = ceil(ranuni(seed_value) * 10000);

-----Original Message----- From: Tim Corn [mailto:tim19972003@YAHOO.COM] Sent: Thursday, May 15, 2003 4:26 PM To: SAS-L@LISTSERV.UGA.EDU Subject: Generate Random Number???

Hello,

I want to generate an unique random number for each observation of a sas dataset. And the range of the random number should be 1~10,000. How can I do this? I tried using ranuni function, but the numbers are less than 1. Any suggetion? Thank in advance for your valuable advice!

Tim

--------------------------------- Do you Yahoo!? The New Yahoo! Search - Faster. Easier. Bingo.

--------------------------------- Do you Yahoo!? The New Yahoo! Search - Faster. Easier. Bingo.


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