Entering edit mode
mictadlo
▴
10
@mictadlo-10885
Last seen 4.8 years ago
How is it possible to get a legend outside plotMDS?
pch <- c(0,1,2,15,16,17)
colors <- rep(c("darkgreen", "red", "blue"), 2)
plotMDS(y, col=colors[group], pch=pch[group])
legend("topleft", legend=levels(group), pch=pch, col=colors, ncol=2)
Thank you in advance.
Or alternatively, if you are a fan of the tidyverse,