title: Can't sort a column in a dataframe even though I'm comparing integers
body: <p>I scraped a table from a website which is full of hockey players with their statistics. The default is sorted by their name while I'm trying to sort it by points. However even though the points column are all integers (I checked), it won't compare the numbers saying they are "lxml.etree._ElementUnicodeResult". Any help greatly appreciated!</p>
  
  <p>I tried running a small bubble sort with a for loop but it didn't work, but for some reason when I used the index positions 0 and 1 instead of I and I+1 it works. I checked and each element is in fact type 'int' so I'm not sure why it changes when I use a loop.</p>
  
  <pre><code>#This was the generic bubble sort that doesn't work    
  #The error is TypeError: '&lt;' not supported between instances of 'int' and 'lxml.etree._ElementUnicodeResult'
  for i in range(1,100):
      if (Dict['PTS'][i]) &lt; (Dict['PTS'][i+1]):
          Dict['PTS'][i], Dict['PTS'][i+1] = Dict['PTS'][i+1], Dict['PTS'][I]
  
  #But when I run this, the first two elements are switched and their are #no problems.
  if (Dict['PTS'][0]) &lt; (Dict['PTS'][1]):
      Dict['PTS'][0], Dict['PTS'][1] = Dict['PTS'][1], Dict['PTS'][0]
  </code></pre>
  
  <p>I tried using the built in sort methods both sorted() and .sort_index but both have the same error as above</p>