How to create this scatter plot with clusters in mclust package in r?

172 Views Asked by At
library(tidyverse)
library(mclust)
mc <- Mclust(iris[,-5])
pairs(mc$data, pch = mc$classification)

This figure gives me all pairs of multiple scatter plots of K = 2 clusters for Iris data. Now I want to focus on Sepal.Length VS Sepal.Width, and add cluster (ellipsoids) in the figure. In other words, I want to replicate this figure below:

enter image description here

0

There are 0 best solutions below