Seaborn を使ったデータ可視化入門
Content Team
DataCamp
2つの量的変数の関係を示す
これまでに見てきた内容:
colとrow)hue)新しいカスタマイズ:
scatterplot()とrelplot()の両方で使用できる
import seaborn as sns import matplotlib.pyplot as plt sns.relplot(x="total_bill", y="tip", data=tips, kind="scatter", size="size")plt.show()

import seaborn as sns import matplotlib.pyplot as plt sns.relplot(x="total_bill", y="tip", data=tips, kind="scatter", size="size", hue="size")plt.show()

import seaborn as sns import matplotlib.pyplot as plt sns.relplot(x="total_bill", y="tip", data=tips, kind="scatter", hue="smoker", style="smoker")plt.show()

import seaborn as sns import matplotlib.pyplot as plt # Set alpha to be between 0 and 1 sns.relplot(x="total_bill", y="tip", data=tips, kind="scatter", alpha=0.4)plt.show()

Seaborn を使ったデータ可視化入門