title: Create a factor variable using the quantiles
body: <p>I'd like to create a factor variable using the quantiles of an other variable A.</p>
  
  <p>I tried this code :</p>
  
  <pre><code>&gt; cut(value, breaks=quantile(value, probs=seq(0,1, by=0.25)),
        include.lowest=TRUE))
  </code></pre>
  
  <p>But it doesn't work because some of the quantiles are the same, so it doesn't know how to cut.</p>
  
  <pre><code>&gt;  'breaks' are not unique
  </code></pre>
  
  <p>Example : q1=2 q2=5 q3=5 q4=8</p>
  
  <p>How can I do in this case ? Maybe we can cut randomly in this case</p>