title: How do I reindex a pandas DataFrame while also resampling it and aggregating its data according to the new index?
body: <p><strong>1) I have the following 1-minute-frequency-data in a pandas DataFrame:</strong></p>
  <div class="s-table-container">
  <table class="s-table">
  <thead>
  <tr>
  <th style="text-align: left;">0</th>
  <th style="text-align: left;">Open</th>
  <th style="text-align: left;">High</th>
  <th style="text-align: left;">Low</th>
  <th style="text-align: left;">Close</th>
  <th style="text-align: left;">Volume</th>
  </tr>
  </thead>
  <tbody>
  <tr>
  <td style="text-align: left;">2010-10-19 06:31:00</td>
  <td style="text-align: left;">58.75</td>
  <td style="text-align: left;">58.81</td>
  <td style="text-align: left;">58.58</td>
  <td style="text-align: left;">58.59</td>
  <td style="text-align: left;">228125</td>
  </tr>
  <tr>
  <td style="text-align: left;">2010-10-19 06:32:00</td>
  <td style="text-align: left;">58.59</td>
  <td style="text-align: left;">58.68</td>
  <td style="text-align: left;">58.55</td>
  <td style="text-align: left;">58.57</td>
  <td style="text-align: left;">153303</td>
  </tr>
  <tr>
  <td style="text-align: left;">2010-10-19 06:33:00</td>
  <td style="text-align: left;">58.57</td>
  <td style="text-align: left;">58.6</td>
  <td style="text-align: left;">58.5</td>
  <td style="text-align: left;">58.52</td>
  <td style="text-align: left;">115647</td>
  </tr>
  <tr>
  <td style="text-align: left;">2010-10-19 06:34:00</td>
  <td style="text-align: left;">58.52</td>
  <td style="text-align: left;">58.58</td>
  <td style="text-align: left;">58.48</td>
  <td style="text-align: left;">58.58</td>
  <td style="text-align: left;">63577</td>
  </tr>
  <tr>
  <td style="text-align: left;">2010-10-19 06:35:00</td>
  <td style="text-align: left;">58.57</td>
  <td style="text-align: left;">58.59</td>
  <td style="text-align: left;">58.51</td>
  <td style="text-align: left;">58.53</td>
  <td style="text-align: left;">111770</td>
  </tr>
  </tbody>
  </table>
  </div>
  <p><strong>2) I also have the following index array:</strong></p>
  <p>[2010-10-19 06:32:00, 2010-10-19 06:35:00]</p>
  <p><strong>3) I want to reindex the DataFrame according to the index array</strong> such that the new DataFrame will only have the 2 rows of the index array, while managing to resample it so that the high of the first row of the new dataframe is the higher of the highs from the first 2 rows of the original dataframe, the low of the second row of the new dataframe is the lower of the 3 lows in the original dataframe, etc.</p>
  <p>Normally, one would aggregate one's data via .resample() and .agg(), but that's once you already have the dataframe in the state that you want. I can't use reindex() in such a way that I could follow it up with .resample() and accomplish this.</p>
  <p>I suppose I'm looking for a way to reindex and resample in one move. How do I best do this?</p>