is it possible to get rid of the cycle?
Here is my input data
import matplotlib.pyplot as plt
frac = [0.75, 0.6093, 0.7025, 0.0437, 0.1]
plt.figure()
orange, blue = '#fd7f28', '#2678b2'
Then this ugly cycle
for i in range(0,5):
plt.bar(0.5+i, frac[i], color=blue)
plt.bar(0.5+i, 1-frac[i], bottom=frac[i], color=orange)
.
plt.xticks([0.5, 1.5, 2.5, 3.5, 4.5], ['AR', 'BR', 'PE', 'RU', 'US'],
rotation='horizontal')
plt.ylabel("Fraction")
plt.xlabel("")
plt.show()
Can I do it without a cycle?


