0
3D 그리드 눈금 선의 색상을 변경하는 방법을 찾고 있었고 깨끗하고 쉬운 방법을 찾을 수 없었습니다. 내가 찾은 유일한 대답은 here이며 조금 복잡해졌습니다. 쉽게 mpl_toolkits.mplot3d
Matplotlib color 3D 눈금 선
간단한 예제를 사용하기 matplotlib에서 3D 플롯의 눈금 선을 색칠하는 방법은 단일 라인에 색깔을 입 힙니다 때문에 here
import matplotlib as mpl
from mpl_toolkits.mplot3d import Axes3D
import numpy as np
import matplotlib.pyplot as plt
mpl.rcParams['legend.fontsize'] = 10
fig = plt.figure()
ax = fig.gca(projection='3d')
theta = np.linspace(-4 * np.pi, 4 * np.pi, 100)
z = np.linspace(-2, 2, 100)
r = z**2 + 1
x = r * np.sin(theta)
y = r * np.cos(theta)
ax.plot(x, y, z, label='parametric curve')
ax.legend()
plt.show()