title: How to change linestyle in matplotlib Step function?
body: <pre><code>x1 = [1, 2, 3, 4, 5, 6]
  y1 = [6, 5, 4, 3, 2, 1]
  
  fig = plt.figure()
  ax = fig.add_subplot(211)
  ax.step(x1, y1, alpha=0.8, linewidth=2, color="b", linestyle="--", label="test")
  </code></pre>
  
  <p><img src="https://i.stack.imgur.com/nr3uI.png" alt="enter image description here"></p>
  
  <p>Why the linestyle parameter doesn't effect this plot? And how to make it work?
  The documentation mentions "Additional keyword args to step() are the same as those for plot()." <a href="http://matplotlib.org/api/axes_api.html?highlight=step#matplotlib.axes.Axes.step" rel="nofollow noreferrer">(doc)</a></p>