title: Pandas Int64Index with dtype=float
body: <p>I am relatively new to pandas. I have stumbled onto problems with slicing a pandas DataFrame when an index that originally contained integers has been manipulated such that it contains floats. Consider the following example (somewhat contrived to make it stand on its own; in practice, data are loaded from file):</p>
  
  <pre><code>df = pd.DataFrame({'i': np.linspace(0, 5, 6).astype(np.int64), 
                     'j': np.linspace(2, 3, 6)})
  df.set_index('i', inplace=True)
  print(df.index)   # Int64Index([0, 1, 2, 3, 4, 5], dtype='int64')
  df.index = df.index / 10.
  print(df.index)   # Int64Index([0.0, 0.1, 0.2, 0.3, 0.4, 0.5], dtype='float64')
  df[:0.3]
  </code></pre>
  
  <p>The final line raises this exception:</p>
  
  <pre><code>TypeError: the slice stop value [None] is not a proper indexer 
  for this index type (Int64Index)
  </code></pre>
  
  <p>While it was relatively easy to work around this using an explicit cast along the lines of</p>
  
  <pre><code>df.index = np.asarray(df.index, dtype=np.float64) / 10.
  </code></pre>
  
  <p>it took me quite a while to figure out what was going on. What I expected to happen in the original code was that the index would become a <code>Float64Index</code> or something similar. When I first noticed the <code>Int64Index</code> with <code>dtype=float</code> I thought that was wierd. Is there some best practice or similar that I should have followed to avoid this problem?</p>
  
  <p>My pandas version is 0.15.2 on python 3.4.</p>