title: Very slow indexing in Pandas 0.15 compared to 0.13.1
body: <p>I use pandas daily in my work. I recently upgraded to 0.15.1 from 0.13.1 and now a bunch of code is too slow to finish when iterating through relatively small DataFrames.</p>
  
  <p>(I realize there are often better/faster ways to accomplish iteration on a DataFrame, but sometimes it's very clear and succinct to have a for loop structure)</p>
  
  <p>I narrowed the problem down to an issue when mixing types:</p>
  
  <pre><code>def iterGet(df,col):
      for i in df.index:
          tmp = df[col].loc[i]
  
  def iterLocSet(df,col,val):
      for i in df.index:
          #df[col].loc[i] = val
          df.loc[i,col] = val
          df.at[i,col] = val
  return df
  
  N = 100
  df = pd.DataFrame(rand(N,3),columns = ['a','b','c'])
  
  df['listCol'] = [[] for i in range(df.shape[0])]
  df['strCol'] = [str(i) for i in range(df.shape[0])]
  df['intCol'] = [i for i in range(df.shape[0])]
  df['float64Col'] = [float64(i) for i in range(df.shape[0])]
  
  print df.a[:5]
  
  %time iterGet(df[['a','intCol']].copy(),'a')
  %time tmpDf = iterLocSet(df[['a','intCol']].copy(),'a',0.)
  print tmpDf.a[:5]
  
  %time iterGet(df[['a','float64Col']].copy(),'a')
  %time tmpDf = iterLocSet(df[['a','float64Col']].copy(),'a',0.)
  print tmpDf.a[:5]
  </code></pre>
  
  <p>On Pandas 0.15.1 the result is:</p>
  
  <pre><code>0    0.114738
  1    0.586447
  2    0.296024
  3    0.446697
  4    0.720984
  Name: a, dtype: float64
  Wall time: 6 ms
  Wall time: 3.41 s
  0    0
  1    0
  2    0
  3    0
  4    0
  Name: a, dtype: float64
  Wall time: 6 ms
  Wall time: 18 ms
  0    0
  1    0
  2    0
  3    0
  4    0
  Name: a, dtype: float64
  </code></pre>
  
  <p>But on Pandas 0.13.1 the result is this:</p>
  
  <pre><code>0    0.651796
  1    0.738661
  2    0.885366
  3    0.513006
  4    0.846323
  Name: a, dtype: float64
  Wall time: 6 ms
  Wall time: 14 ms
  0    0
  1    0
  2    0
  3    0
  4    0
  Name: a, dtype: float64
  Wall time: 5 ms
  Wall time: 15 ms
  0    0
  1    0
  2    0
  3    0
  4    0
  Name: a, dtype: float6
  </code></pre>
  
  <p>It appears that making an assignment using row-indexing on a multi-typed array is ~200x slower in Pandas 0.15.1?</p>
  
  <p>I am aware there may be a potential pitfall here by assigning to what may be a copy of the array, but I admit I do not fully understand that issue either. Here at least I can see the assignment is working. <em>EDIT</em> Although I see now that using either of these in the for loop fixes the problem:</p>
  
  <pre><code>df.loc[i,col] = val
  df.at[i,col] = val
  </code></pre>
  
  <p>I don't know enough about the implementation to diagnose this. Can anyone reproduce this? Is this what you would expect? What am I doing wrong?
  Thanks!</p>