[R] RNG

Gustaf Rydevik gustaf.rydevik at gmail.com
Wed Apr 21 16:42:29 CEST 2010


On Wed, Apr 21, 2010 at 4:37 PM, tamas barjak <tamas.barjak at gmail.com> wrote:
> Hi all!
>
> I would like to generate random numbers between 0 and 1. How can I do this?
> I downloaded it single RNG but it generates ones between only 1 and
> 10000...:(
>
> Thank you for the help!
>
> Tamas
>

Hi tamas,

I am not sure what you mean by  "downloaded".... There is a lot of
random number generators built into R.

To generate 10 random numbers between 0 and 1, try

runif(10)

Regards,
Gustaf



-- 
Gustaf Rydevik, M.Sci.
tel: +46(0)703 051 451
address:Essingetorget 40,112 66 Stockholm, SE
skype:gustaf_rydevik



More information about the R-help mailing list