pandas.io.formats.style.Styler.set_tooltips
pandas 3.1.1 · Styling · method
Attach hover text to matching cells in HTML output.
Call syntax
Styler.set_tooltips(ttips, props=None, css_class=None, as_title_attribute=False)Run the example
Edit the example and select Run Python to see the result.
Parameters
| Parameter | Requirement | Accepted values and behavior |
|---|---|---|
ttips |
Required Positional or keyword |
DataFrame |
props |
Optional Positional or keyword Default None |
list-like or str Supply CSS property declarations or the styles applied to matching cells. |
css_class |
Optional Positional or keyword Default None |
str |
as_title_attribute |
Optional Positional or keyword Default False |
bool |
Returns
Styler