title: Barplot/line plot on same plot, but different axis and line plot in front of barplot
body: <p>I'm using pandas to plot some data. </p>
  
  <p>If I plot this:</p>
  
  <pre class="lang-py prettyprint-override"><code>import pandas as pd
  import matplotlib.pyplot as plt
  
  df = pd.DataFrame({'a': [100, 200, 150, 175],
                     'b': [430, 30, 20, 10]})
  fig, ax1 = plt.subplots(figsize=(15, 10))
  df['b'].plot(kind='bar', color='y')
  df['a'].plot(kind='line', marker='d')
  </code></pre>
  
  <p>Everything plots fine. </p>
  
  <p><a href="https://i.stack.imgur.com/6XAAJ.png" rel="noreferrer"><img src="https://i.stack.imgur.com/6XAAJ.png" alt="GoodGraph"></a></p>
  
  <p>If I plot the bar axis on the secondary axis, the bar plot will be in front of the line plots, obstructing the lines from being viewed, like this.</p>
  
  <pre class="lang-py prettyprint-override"><code>import pandas as pd
  import matplotlib.pyplot as plt
  
  df = pd.DataFrame({'a': [100, 200, 150, 175],
                     'b': [430, 30, 20, 10]})
  fig, ax1 = plt.subplots(figsize=(15, 10))
  df['b'].plot(kind='bar', color='y', secondary_y=True)
  df['a'].plot(kind='line', marker='d')
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/L6SAC.png" rel="noreferrer"><img src="https://i.stack.imgur.com/L6SAC.png" alt="SadGraph"></a></p>
  
  <p>How do I make a bar plot/line plot where...</p>
  
  <ul>
  <li>Using pandas/matplotlib</li>
  <li>Bar plot is on secondary axis and line chart is on primary axis</li>
  <li>Line plots are in front of the bar plot</li>
  </ul>