fig, axes = plt.subplots(nrows=1, ncols=5)data.Interest1.value_counts().plot(kind = 'bar', ax=axes[0,0], color = "rosybrown")massT5.Interest1.value_counts().plot(kind ='bar', ax=axes[0,1], color = "firebrick")scT5.Interest1.value_counts().plot(kind ='bar', ax=axes[0,2], color = "red")virgT5.Interest1.value_counts().plot(kind ='bar', ax=axes[0,3],color = "darksalmon")nyT5.Interest1.value_counts().plot(kind ='bar' , ax=axes[0,4],color = "sienna")我正在尝试绘制 5 个不同的图,但当我更改时,我不知道如何摆脱底部的行fig, axes = plt.subplots(nrows=5, ncols=5)到fig, axes = plt.subplots(nrows=1, ncols=5)我收到一条错误消息 IndexError:数组索引太多。提前致谢
添加回答
举报
0/150
提交
取消