title: Generate 3 random number that sum to 1 in R
body: <p>I am hoping to create 3 (non-negative) quasi-random numbers that sum to one, and repeat over and over.  </p>
  
  <p>Basically I am trying to partition something into three random parts over many trials.  </p>
  
  <p>While I am aware of </p>
  
  <pre><code>a = runif(3,0,1)
  </code></pre>
  
  <p>I was thinking that I could use <code>1-a</code> as the max in the next <code>runif</code>, but it seems messy.</p>
  
  <p>But these of course don't sum to one. Any thoughts, oh wise stackoverflow-ers?</p>