pandas-df-variable-name (PD901)
Derived from the pandas-vet linter.
Warning: This rule has been removed and its documentation is only available for historical reasons.
Removed
This rule has been removed as it's highly opinionated and overly strict in most cases.
What it does
Checks for assignments to the variable df
.
Why is this bad?
Although df
is a common variable name for a Pandas DataFrame
, it's not a
great variable name for production code, as it's non-descriptive and
prone to name conflicts.
Instead, use a more descriptive variable name.
Example
Use instead: