我对python很新,最近开始学习seaborn。当我运行代码时,没有回溯,并且网格显示在新窗口中。但问题是没有显示FaceGrid的图像,显示了distplot。不确定发生了什么,真的很感激,如果有人能帮助我!谢谢你!
import pandas as pd
import seaborn as sns
import matplotlib as plt
train = pd.read_csv("train.csv")
train["Age"] = train["Age"].fillna(train["Age"].median())
#THIS ONE IS NOT SHOWN
sns.FacetGrid(train, col='Survived', row='Pclass', size=2.2, aspect=1.6)
#THIS ONE WAS SHOWED
sns.distplot(train['Age'])
sns.plt.show()