2015-02-02 2 views

답변

0

Internallyhist2dnumpy.histogram2d을 사용합니다. 따라서이 함수를 사용하여 두 히스토그램을 계산하고 비율을 계산 한 다음 pcolormesh, imshow 또는 이와 유사한 값을 사용하여 그래프를 그릴 수 있습니다.

h1, xedges, yedges = np.histogram2d(x1, y1, bins=bins) 
h2, xedges, yedges = np.histogram2d(x2, y2, bins=bins) 
h = h1/h2 
pc = ax.pcolorfast(xedges, yedges, h.T)