I have a Python Pandas DataFrame
object containing textual data. My problem is, that when I use to_html()
function, it truncates the strings in the output.
For example:
import pandas
df = pandas.DataFrame({'text': ['Lorem ipsum dolor sit amet, consectetur adipiscing elit.']})
print (df.to_html())
The output is truncated at adapis...
<table border="1" class="dataframe">
<thead>
<tr style="text-align: right;">
<th></th>
<th>text</th>
</tr>
</thead>
<tbody>
<tr>
<th>0</th>
<td> Lorem ipsum dolor sit amet, consectetur adipis...</td>
</tr>
</tbody>
</table>
There is a related question on SO, but it uses placeholders and search/replace functionality to postprocess the HTML, which I would like to avoid:
Is there a simpler solution to this problem? I could not find anything related from the documentation.
Question&Answers:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…