PCoA plots with confidence ellipsoids for only some groups

Hi there!!

I loved your answer... so clear!!

I was trying to change the ellipse, to add ellipse just to two of the factors. My script when working with personal data it would be something like:

stat_ellipse(level = 0.9, geom = "polygon", aes(fill = after_scale(alpha(colour, 0.3))),
data = wunifrac[contents$files.Date != "July",])

However, I dont know how to call for my value July in my factor Date...

Thank you in advance!

1 Like

Hello Ana,

You are on the right track! Passing filtered data to stat_ellipse is the way:

1 Like

Thank you very very much!!