Skip to content

Commit e754f8b

Browse files
authored
update Axes.grid to support matplotlib >= 3.5 (#254)
1 parent 74226f5 commit e754f8b

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

impedance/visualization.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ def plot_nyquist(Z, scale=1, units='Ohms', fmt='.-', ax=None, labelsize=20,
5555
ax.locator_params(axis='y', nbins=5, tight=True)
5656

5757
# Add a light grid
58-
ax.grid(b=True, which='major', axis='both', alpha=.5)
58+
ax.grid(visible=True, which='major', axis='both', alpha=.5)
5959

6060
# Change axis units to 10**log10(scale) and resize the offset text
6161
limits = -np.log10(scale)
@@ -126,7 +126,7 @@ def plot_bode(f, Z, scale=1, units='Ohms', fmt='.-', axes=None, labelsize=20,
126126
ax.locator_params(axis='y', nbins=5, tight=True)
127127

128128
# Add a light grid
129-
ax.grid(b=True, which='major', axis='both', alpha=.5)
129+
ax.grid(visible=True, which='major', axis='both', alpha=.5)
130130

131131
# Change axis units to 10**log10(scale) and resize the offset text
132132
limits = -np.log10(scale)
@@ -323,7 +323,7 @@ def plot_residuals(ax, f, res_real, res_imag, fmt='.-', y_limits=(-5, 5),
323323
ax.locator_params(axis='y', nbins=4, tight=True)
324324

325325
# Add a light grid
326-
ax.grid(b=True, which='major', axis='both', alpha=.5)
326+
ax.grid(visible=True, which='major', axis='both', alpha=.5)
327327
ax.legend(fontsize=14)
328328

329329
ax.set_ylim(y_limits)

requirements.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
altair>=3.0
22
coveralls==3.2.0
3-
matplotlib>=3.0
3+
matplotlib>=3.5
44
numpy>=1.14
55
numpydoc
66
nbsphinx

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
url="https://impedancepy.readthedocs.io/en/latest/",
1616
packages=setuptools.find_packages(),
1717
python_requires="~=3.7",
18-
install_requires=['altair>=3.0', 'matplotlib>=3.0',
18+
install_requires=['altair>=3.0', 'matplotlib>=3.5',
1919
'numpy>=1.14', 'scipy>=1.0'],
2020
classifiers=(
2121
"Programming Language :: Python :: 3",

0 commit comments

Comments
 (0)