title: IF function doesn't display df as expected in Python
body: <p>Rookie question here, I can't understand why this if function isn't returning the previously generated df. </p>
  
  <p>df is 821 rows long, and <code>print len(output_df.index)&gt;10000</code> yields <code>False</code>. </p>
  
  <p>If statement is the following:</p>
  
  <pre><code>if len(output_df.index)&gt;10000:
      print("Table is too large to display, download above")
  else:
      HTML(output_df.to_html())
  </code></pre>
  
  <p>I also tried:</p>
  
  <pre><code>if len(output_df.index)&gt;10000:
      print("Table is too large to display, download above")
  else:
      return HTML(output_df.to_html())
  </code></pre>
  
  <p>and:</p>
  
  <pre><code>if len(output_df.index)&gt;10000:
      print("Table is too large to display, download above")
  else:
      output_df
  </code></pre>
  
  <p>to no avail. Invoking the table in another cell works just fine. Any ideas? Thank you!</p>