Skip to content

Commit ed7ce68

Browse files
Terji Petersentopper-123
Terji Petersen
authored andcommitted
use _holds_integer in plotting._atplotlib.core.py
1 parent 5291064 commit ed7ce68

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

pandas/plotting/_matplotlib/core.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1196,7 +1196,7 @@ def __init__(self, data, x, y, s=None, c=None, **kwargs) -> None:
11961196
elif is_hashable(s) and s in data.columns:
11971197
s = data[s]
11981198
super().__init__(data, x, y, s=s, **kwargs)
1199-
if is_integer(c) and self.data.columns._should_fallback_to_positional:
1199+
if is_integer(c) and self.data.columns._holds_integer():
12001200
c = self.data.columns[c]
12011201
self.c = c
12021202

@@ -1291,7 +1291,7 @@ def _kind(self) -> Literal["hexbin"]:
12911291

12921292
def __init__(self, data, x, y, C=None, **kwargs) -> None:
12931293
super().__init__(data, x, y, **kwargs)
1294-
if is_integer(C) and self.data.columns._should_fallback_to_positional:
1294+
if is_integer(C) and self.data.columns._holds_integer():
12951295
C = self.data.columns[C]
12961296
self.C = C
12971297

0 commit comments

Comments
 (0)