Subscript and superscript in python pandas column names

Viewed 4182

Is it possible to format a column name in Pandas to have subscripts superscripts? I tried using dollars as $x_a^2$:

import pandas as pd
pd.DataFrame(list([1,2,3]),columns=['$x_a^2$'])

but in jupyter notebook I get a strange | character in the end enter image description here

0 Answers
Related