Could we change colors for groups from being defined by an array of colors to being a dict mapping from the relevant key/ category to the color? I would find this more intuitive, and much easier to modify. Plus tools like seaborn can accept dicts directly as a palette:
import seaborn as sns
iris = sns.load_dataset("iris")
g = sns.FacetGrid(
iris,
row="species",
hue="species",
palette={"setosa": "red", "versicolor": "green", "virginica": "blue"}
)
g.map(sns.kdeplot, "sepal_width").show()
