Вопрос

I want to show the axis ticks with matplotlib/mplot3d but not the faint grids on the x/y/z background:

enter image description here

Is there a way to suppress the grids?

Это было полезно?

Решение

Calling ax.grid(False) should suffice. Self contained example, adding that line to this:

from mpl_toolkits.mplot3d import axes3d
import matplotlib.pyplot as plt
import numpy as np

fig = plt.figure()
ax = fig.add_subplot(111, projection='3d')
ax.grid(False)
X, Y, Z = axes3d.get_test_data(0.05)
ax.plot_wireframe(X, Y, Z, rstride=10, cstride=10)

plt.show()
Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top