title: return last date and value each month in pandas
body: <p>I have a df in pandas with daily data. I would like to return the last value of each month. I thought the simple solution would be to <code>.resample("M").apply(lambda ser: ser.iloc[-1,])</code> however, it seems as if <code>resample</code> actually computes the month end date rather than return the actual date that appears that month. Is this intended behavior? MWE:</p>
  
  <pre><code>import pandas as pd
  import numpy as np
  df = pd.Series(np.arange(100), index=pd.date_range(start="2000-01-02", periods=100)).to_frame()
  df.sort_index().resample("M").apply(lambda ser: ser.iloc[-1,])
  #             0
  #2000-01-31  29
  #2000-02-29  58
  #2000-03-31  89
  #2000-04-30  99
  </code></pre>
  
  <p>While the last date appearing in <code>df</code> is <code>2000-04-10</code></p>