title: Make Number of Rows Based on Column Values - Pandas/Python
body: <p>I want to expand my data frame based on numeric values in two columns (<code>index_start</code> and <code>index_end</code>). My df looks like this:</p>
  <pre><code>item  index_start  index_end    
  A          1            3
  B          4            7
  </code></pre>
  <p>I want this to expand to create rows for A from 1 to 3 and rows for B from 4 to 7 like so.</p>
  <pre><code>item  index_start  index_end    index
  A          1            3         1
  A          1            3         2
  A          1            3         3
  B          4            7         4
  B          4            7         5
  B          4            7         6
  B          4            7         7
  </code></pre>
  <p>Unsure how to implement this in Python/pandas.</p>