问题
i have image containing 4 subplots:
#!/usr/bin/env python3
import matplotlib.pyplot as plt
f, axarr = plt.subplots(2, 2)
axarr[0,1].stem([1,3,-4],linefmt='b-', markerfmt='bs', basefmt='k-')
plt.show()
I want to change the linewidth of one plot (stem plot). Is there an easy way to do this?
回答1:
Here is my solution:
markerline, stemlines, baseline = plt.stem(x, y)
plt.setp(stemlines, 'linewidth', 3)
来源:https://stackoverflow.com/questions/32953201/matplotlib-change-stem-plot-linewidth