text: user467: Is it possible to draw e.g. 95% confidence ellipses around samples from the same group on the results from the plotMDS function under edgeR? If so, how?
  
  user235: I can see that there would be a three step process to doing this:
  
  Merge counts from all samples in the group and then resample pseudo-replicates from this. If x is a matrix with samples in the group being columns and genes being rows
  s <- sample(row.names(x), n = mean(colSums(x)), probs=rowSums(x)/sum(rowSums(x))
  stab <- table(s)
  s <- as.vector(stab)
  names(s) <- names(stab)
  
  Do this thousands of times.
  You would then want to project those onto your MDS plot space - i'm less clear about how you could do this without perturbing the space itself.
  Calculate the parameter for an ellipise that would contain 95% of these points. Again, I'm not so sure about how to do this, but I think the car pacakge might be a good place to start looking.
  
  
original_text: 467: <p>Is it possible to draw e.g. 95% confidence ellipses around samples from the same group on the results from the plotMDS function under edgeR? If so, how?</p>
   235: <p>I can see that there would be a three step process to doing this:</p>
  
  <ol>
  <li><p>Merge counts from all samples in the group and then resample pseudo-replicates from this. If <code>x</code> is a matrix with samples in the group being columns and genes being rows</p>
  
  
  
  <pre><code>s &lt;- sample(row.names(x), n = mean(colSums(x)), probs=rowSums(x)/sum(rowSums(x))
  stab &lt;- table(s)
  s &lt;- as.vector(stab)
  names(s) &lt;- names(stab)
  </code></pre>
  
  <p>Do this thousands of times.</p></li>
  <li><p>You would then want to project those onto your MDS plot space - i'm less clear about how you could do this without perturbing the space itself.</p></li>
  <li><p>Calculate the parameter for an ellipise that would contain 95% of these points. Again, I'm not so sure about how to do this, but I think the <code>car</code> pacakge might be a good place to start looking.</p></li>
  </ol>
  