pandas.DataFrame.gt

pandas 3.1.1 · DataFrame · method

Compare corresponding values using greater-than.

Call syntax

DataFrame.gt(other, axis='columns', level=None)

Run the example

Edit the example and select Run Python to see the result.

Parameters

ParameterRequirementAccepted values and behavior
other Required
Positional or keyword
scalar, sequence, Series, or DataFrame

Supply the second object or value used in the operation.

axis Optional
Positional or keyword
Default 'columns'
{0 or 'index', 1 or 'columns'}

Choose which axis the operation acts on. The accepted axis labels depend on the receiver.

level Optional
Positional or keyword
Default None
int or label

Choose an index level by name or integer position.

Returns

DataFrame of bool