Uwe Ligges
> Cc: r-help; Alexander Engelhardt
> Subject: Re: [R] How to draw 4 random weights that sum up to 1?
>
>
> On Oct 10, 2011, at 12:44 PM, Uwe Ligges wrote:
>
> >
> >
> > On 10.10.2011 18:10, Alexander Engelhardt wrote:
> >> Hey list,
> &g
On Oct 10, 2011, at 12:44 PM, Uwe Ligges wrote:
On 10.10.2011 18:10, Alexander Engelhardt wrote:
Hey list,
This might be a more general question and not that R-specific.
Sorry for
that.
I'm trying to draw a random vector of 4 numbers that sum up to 1.
My first approach was something lik
On 10.10.2011 18:10, Alexander Engelhardt wrote:
Hey list,
This might be a more general question and not that R-specific. Sorry for
that.
I'm trying to draw a random vector of 4 numbers that sum up to 1.
My first approach was something like
a <- runif(1)
b <- runif(1, max=1-a)
c <- runif(1,
; Subject: [R] How to draw 4 random weights that sum up to 1?
>
> Hey list,
>
> This might be a more general question and not that R-specific. Sorry
> for
> that.
>
> I'm trying to draw a random vector of 4 numbers that sum up to 1.
> My first approach was something
Hey list,
This might be a more general question and not that R-specific. Sorry for
that.
I'm trying to draw a random vector of 4 numbers that sum up to 1.
My first approach was something like
a <- runif(1)
b <- runif(1, max=1-a)
c <- runif(1, max=1-a-b)
d <- 1-a-b-c
but this kind of
5 matches
Mail list logo