Skip to content

Instantly share code, notes, and snippets.

@dipanjanS
Created January 10, 2018 19:32
Show Gist options
  • Save dipanjanS/2a328a8fe7ffc3bf9b92234539bab13a to your computer and use it in GitHub Desktop.
Save dipanjanS/2a328a8fe7ffc3bf9b92234539bab13a to your computer and use it in GitHub Desktop.
# Visualizing 3-D mix data using scatter plots
# leveraging the concepts of hue for categorical dimension
jp = sns.pairplot(wines, x_vars=["sulphates"], y_vars=["alcohol"], size=4.5,
hue="wine_type", palette={"red": "#FF9999", "white": "#FFE888"},
plot_kws=dict(edgecolor="k", linewidth=0.5))
# we can also view relationships\correlations as needed
lp = sns.lmplot(x='sulphates', y='alcohol', hue='wine_type',
palette={"red": "#FF9999", "white": "#FFE888"},
data=wines, fit_reg=True, legend=True,
scatter_kws=dict(edgecolor="k", linewidth=0.5))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment