pandas / 1.4.0 / reference / api / pandas.option_context.html /

pandas.option_context

class pandas. option_context ( *args ) [source]

Context manager to temporarily set options in the with statement context.

You need to invoke as option_context(pat, val, [(pat, val), ...]).

Examples

>>> with option_context('display.max_rows', 10, 'display.max_columns', 5):
...     pass

Methods

__call__(func)

Call self as a function.

© 2008–2022, AQR Capital Management, LLC, Lambda Foundry, Inc. and PyData Development Team
Licensed under the 3-clause BSD License.
https://pandas.pydata.org/pandas-docs/version/1.4.0/reference/api/pandas.option_context.html