Skip to content

Commit be9e0bd

Browse files
new change
1 parent 1314059 commit be9e0bd

File tree

1 file changed

+13
-2
lines changed

1 file changed

+13
-2
lines changed

pandas/plotting/_core.py

+13-2
Original file line numberDiff line numberDiff line change
@@ -309,10 +309,21 @@ def _setup_subplots(self):
309309

310310
axes = _flatten(axes)
311311

312-
if self.logx or self.loglog:
312+
valid_log = [False, True, 'sym', None]
313+
314+
for i in (self.logx, self.logy, self.loglog):
315+
if i not in valid_log:
316+
raise ValueError("Valid inputs are boolean, None and 'sym'.")
317+
318+
if self.logx is True or self.loglog is True:
313319
[a.set_xscale('log') for a in axes]
314-
if self.logy or self.loglog:
320+
elif self.logx == 'sym' or self.loglog == 'sym':
321+
[a.set_xscale('symlog') for a in axes]
322+
323+
if self.logy is True or self.loglog is True:
315324
[a.set_yscale('log') for a in axes]
325+
elif self.logy == 'sym' or self.loglog == 'sym':
326+
[a.set_yscale('symlog') for a in axes]
316327

317328
self.fig = fig
318329
self.axes = axes

0 commit comments

Comments
 (0)