Skip to content

Commit

Permalink
Add another check for old boxplot/violinplot api
Browse files Browse the repository at this point in the history
  • Loading branch information
mwaskom committed Mar 13, 2015
1 parent 037bf80 commit da20f4e
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions seaborn/categorical.py
Original file line number Diff line number Diff line change
Expand Up @@ -1513,6 +1513,11 @@ def boxplot(x=None, y=None, hue=None, data=None, order=None, hue_order=None,
# This should help with the lack of a smooth deprecation,
# but won't catch everything
warn = False
if isinstance(x, pd.DataFrame):
data = x
x = None
warn = True

if "vals" in kwargs:
x = kwargs.pop("vals")
warn = True
Expand Down Expand Up @@ -1671,6 +1676,11 @@ def violinplot(x=None, y=None, hue=None, data=None, order=None, hue_order=None,
# This should help with the lack of a smooth deprecation,
# but won't catch everything
warn = False
if isinstance(x, pd.DataFrame):
data = x
x = None
warn = True

if "vals" in kwargs:
x = kwargs.pop("vals")
warn = True
Expand Down

0 comments on commit da20f4e

Please sign in to comment.