Initial import (#1468995).
This commit is contained in:
parent
6918dc3a78
commit
3b05287c6d
7 changed files with 331 additions and 3 deletions
30
0001-Fix-default-cmap-for-Matplotlib-2.0.0.patch
Normal file
30
0001-Fix-default-cmap-for-Matplotlib-2.0.0.patch
Normal file
|
|
@ -0,0 +1,30 @@
|
|||
From ff44cd10b0e3bcdb583c034f8450507ed4a461c8 Mon Sep 17 00:00:00 2001
|
||||
From: Elliott Sales de Andrade <quantum.analyst@gmail.com>
|
||||
Date: Tue, 19 Sep 2017 00:48:06 -0400
|
||||
Subject: [PATCH 1/3] Fix default cmap for Matplotlib 2.0.0.
|
||||
|
||||
Signed-off-by: Elliott Sales de Andrade <quantum.analyst@gmail.com>
|
||||
---
|
||||
geopandas/plotting.py | 5 ++++-
|
||||
1 file changed, 4 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/geopandas/plotting.py b/geopandas/plotting.py
|
||||
index 31b6284..a198e50 100644
|
||||
--- a/geopandas/plotting.py
|
||||
+++ b/geopandas/plotting.py
|
||||
@@ -402,8 +402,11 @@ def plot_dataframe(df, column=None, cmap=None, color=None, ax=None,
|
||||
# Define `values` as a Series
|
||||
if categorical:
|
||||
if cmap is None:
|
||||
- if LooseVersion(matplotlib.__version__) >= '2.0':
|
||||
+ if LooseVersion(matplotlib.__version__) >= '2.0.1':
|
||||
cmap = 'tab10'
|
||||
+ elif LooseVersion(matplotlib.__version__) >= '2.0.0':
|
||||
+ # Erroneous name.
|
||||
+ cmap = 'Vega10'
|
||||
else:
|
||||
cmap = 'Set1'
|
||||
categories = list(set(df[column].values))
|
||||
--
|
||||
2.13.6
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue