将哈希模式应用于BAR PLOT

问题描述

我想创建一个列表,可以在其中添加英语国家,并确保该列表能反映在我的地块上

top9 = master_frame[master_frame['country_code'].isin(["USA","CHN","GBR","IND","CAN","ISR","FRA","DEU","SWE"])]

plt.figure(figsize=(10,5))
ax2=sns.barplot(x='country_code',y='raised_amount_usd',data=top9,estimator=np.sum,)
ax2.set_yscale('log')
ax2.set(xlabel='Funding by country',ylabel='Total amount of investments')
ax2.set_title('Investment distribution Country wise',fontsize =18,weight='bold')
plt.show()

输出:

barplot image

这里的挑战是,我需要突出显示以英语为官方语言的国家/地区,所以我的想法是在国家/地区的条形图中添加哈希模式,并在上方显示一个色相框。

有什么主意我能做到吗?

提前谢谢!

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)