我有以下代码以创建条形图。
import matplotlib.pyplot as plt; plt.rcdefaults()
import numpy as np
import matplotlib.pyplot as plt
objects = db.source[:5]
y_pos = np.arange(len(objects))
performance = db.a[:5]
plt.bar(y_pos, performance ,width=0.5, alpha=5, linewidth=2.0, capsize=2)
plt.xticks(y_pos, objects, )
plt.ylabel('Tweet Sayısı')
plt.xlabel('Kaynak')
plt.title('Kaynağa Göre Atılan Tweet Sayıları')
plt.show()
它工作正常,但情节不单独显示x行项目,项目'字母相互混合。你知道如何改变x行中字母的大小或类型吗?