Thanks to visit codestin.com
Credit goes to github.com

Skip to content
Draft
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Fix single_value_kwarg
  • Loading branch information
TLouf committed Sep 26, 2021
commit e1c413a43888750f3e10440bbc6db2b266c06322
5 changes: 2 additions & 3 deletions geopandas/plotting.py
Original file line number Diff line number Diff line change
Expand Up @@ -77,13 +77,12 @@ def _expand_kwargs(kwargs, multiindex, is_final_expansion=False):
from matplotlib.colors import is_color_like
from typing import Iterable

single_value_kwargs = ["hatch", "marker"]
mpl = matplotlib.__version__
if not (mpl >= LooseVersion("3.4") or (mpl > LooseVersion("3.3.2") and "+" in mpl)):
# alpha is supported as array argument with matplotlib 3.4+
scalar_kwargs = ["marker", "path_effects"]
single_value_kwargs = ["hatch", "marker", "path_effects"]
else:
scalar_kwargs = ["marker", "alpha", "path_effects"]
single_value_kwargs = ["hatch", "marker", "alpha", "path_effects"]

for att, value in kwargs.items():
if "color" in att: # color(s), edgecolor(s), facecolor(s)
Expand Down