首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >Python seaborn图形

Python seaborn图形
EN

Stack Overflow用户
提问于 2016-04-06 22:59:50
回答 1查看 336关注 0票数 3

亲爱的所有人,我正在尝试将kaggle教程代码应用于Iris数据集。

不幸的是,当我执行图形的代码时,我只能看到这个输出,而没有看到任何图形:

matplotlib.axes._subplots.AxesSubplot at 0x9abf9b0

有什么想法吗?

这是代码

代码语言:javascript
复制
import warnings # current version of seaborn generates a bunch of warnings that we'll ignore
warnings.filterwarnings("ignore")
import seaborn as sns
import matplotlib.pyplot as plt
sns.set(style="white", color_codes=True)

# Next, we'll load the Iris flower dataset, which is in the "../input/" directory
iris = pd.read_csv("../input/Iris.csv") # the iris dataset is now a Pandas DataFrame

# We'll use this to make a scatterplot of the Iris features.
iris.plot(kind="scatter", x="SepalLengthCm", y="SepalWidthCm")
EN

回答 1

Stack Overflow用户

发布于 2016-04-06 23:04:01

如果使用的是IPython笔记本电脑,只需在绘图前使用%pylab inline命令即可。如果没有,请在完成绘图后尝试使用plt.show()

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/36454951

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档