[R] Laplacian Distribution

Liaw, Andy andy_liaw at merck.com
Tue Jul 6 16:56:09 CEST 2004


How about something like:

n <- 100
x <- sign(runif(n) - 0.5) * rexp(n)

??

Andy

> From: Yao, Minghua
> 
> All,
>  
> Could anybody please tell me how to generate Laplacian 
> distributed random numbers? Thanks.
>  
> Minghua




More information about the R-help mailing list