Skip to content

Pandas.io.formats.style.Styler docstring PR02 #28539

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 11 additions & 7 deletions pandas/io/formats/style.py
Original file line number Diff line number Diff line change
Expand Up @@ -645,7 +645,7 @@ def apply(self, func, axis=0, subset=None, **kwargs):
subset : IndexSlice
a valid indexer to limit ``data`` to *before* applying the
function. Consider using a pandas.IndexSlice
kwargs : dict
**kwargs : dict
pass along to ``func``

Returns
Expand Down Expand Up @@ -697,7 +697,7 @@ def applymap(self, func, subset=None, **kwargs):
subset : IndexSlice
a valid indexer to limit ``data`` to *before* applying the
function. Consider using a pandas.IndexSlice
kwargs : dict
**kwargs : dict
pass along to ``func``

Returns
Expand Down Expand Up @@ -732,7 +732,7 @@ def where(self, cond, value, other=None, subset=None, **kwargs):
subset : IndexSlice
a valid indexer to limit ``data`` to *before* applying the
function. Consider using a pandas.IndexSlice
kwargs : dict
**kwargs : dict
pass along to ``cond``

Returns
Expand Down Expand Up @@ -965,8 +965,10 @@ def background_gradient(
----------
cmap : str or colormap
matplotlib colormap
low, high : float
compress the range by these values.
low : float
compress the range by the low.
high : float
compress the range by the high.
axis : {0 or 'index', 1 or 'columns', None}, default 0
apply to each column (``axis=0`` or ``'index'``), to each row
(``axis=1`` or ``'columns'``), or to the entire DataFrame at once
Expand Down Expand Up @@ -1078,7 +1080,7 @@ def set_properties(self, subset=None, **kwargs):
----------
subset : IndexSlice
a valid slice for ``data`` to limit the style application to
kwargs : dict
**kwargs : dict
property: value pairs to be set for each cell

Returns
Expand Down Expand Up @@ -1350,8 +1352,10 @@ def pipe(self, func, *args, **kwargs):
Function to apply to the Styler. Alternatively, a
``(callable, keyword)`` tuple where ``keyword`` is a string
indicating the keyword of ``callable`` that expects the Styler.
*args, **kwargs :
*args : optional
Arguments passed to `func`.
**kwargs : optional
A dictionary of keyword arguments passed into ``func``.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like there are too many newlines here

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @jbrockmendel, I have removed the extra new line that was added.

Returns
-------
Expand Down