在R中有一个称为海盗图的漂亮图形。它是箱线图和点图的组合。我该如何使用seaborn在Python中绘制类似的图形呢? 您可以在此处找到示例:http://rpubs.com/yarrr/pirateplot
这是我能想到的最接近pirateplot的方法。使用seaborn的boxplot和stripplot两种图表类型。sns.set_style("whitegrid") tips = sns.load_dataset("tips") ax = sns.boxplot(x="day", y="total_bill", data=tips) ax = sns.stripplot(x="day", y="total_bill", data=tips, color=".25") 导致产生这个图表。