title: Pandas Dataframe Mask based on index
body: <p>I have the following dataframe:</p>
  
  <pre><code>import pandas as pd
  index = pd.date_range('2013-1-1',periods=10,freq='15Min')
  data = pd.DataFrame(data=[1,2,3,4,5,6,7,8,9,0], columns=['value'], index=index)
  </code></pre>
  
  <p>How can I generate a mask based on the index value? I know I can do something like:</p>
  
  <pre><code>data['value'] &gt; 3
  Out[40]: 
  2013-01-01 00:00:00    False
  2013-01-01 00:15:00    False
  2013-01-01 00:30:00    False
  2013-01-01 00:45:00     True
  2013-01-01 01:00:00     True
  2013-01-01 01:15:00     True
  2013-01-01 01:30:00     True
  2013-01-01 01:45:00     True
  2013-01-01 02:00:00     True
  2013-01-01 02:15:00    False
  Freq: 15T, Name: value, dtype: bool
  </code></pre>
  
  <p>I want to generate a mask to only consider some rows where the index is in a certain range. I was thinking of doing something like <code>data['index'].time() &gt; datetime.time(1,15)</code> to generate a mask. Except of course <code>data['index']</code> fails because index is not the name of a column. How can you reference the index value for a row in a mask?</p>