title: How to print a pandas.io.formats.style.Styler object
body: <p>I have the following code which produces a pandas.io.formats.style.Styler object:</p>
  
  <pre><code>import pandas as pd
  import numpy as np
  
  df = pd.DataFrame({'text': ['foo foo', 'bar bar'],
                   'number': [1, 2]})
  
  df1 = df.style.set_table_styles([dict(selector='th', props=[('text-align', 'center')])])
  df2 = df1.set_properties(**{'text-align': 'center'}).hide_index()
  df2   # df2 is a pandas.io.formats.style.Styler object
  </code></pre>
  
  <p>How do I print <code>df2</code> if I have more code running underneath the above script, for eg.:</p>
  
  <pre><code>import pandas as pd
  import numpy as np
  
  df = pd.DataFrame({'text': ['foo foo', 'bar bar'],
                   'number': [1, 2]})
  
  df1 = df.style.set_table_styles([dict(selector='th', props=[('text-align', 'center')])])
  df2 = df1.set_properties(**{'text-align': 'center'}).hide_index()
  df2
  
  np.round(0.536, 2)
  </code></pre>
  
  <p>I tried using the print statement but it's giving me an output as below:</p>
  
  <pre><code>import pandas as pd
  import numpy as np
  
  df = pd.DataFrame({'text': ['foo foo', 'bar bar'],
                   'number': [1, 2]})
  
  df1 = df.style.set_table_styles([dict(selector='th', props=[('text-align', 'center')])])
  df2 = df1.set_properties(**{'text-align': 'center'}).hide_index()
  print(df2)
  
  np.round(0.536, 2)
  </code></pre>
  
  <pre><code>&lt;pandas.io.formats.style.Styler object at 0x000000000B4FAFC8&gt;
  0.54
  </code></pre>
  
  <p>Any help would really be appreciated. Many thanks in advance.</p>