I am trying to overlay a scatter plot on a contour plot using matplotlib which contains
plt.contourf(X, Y, XYprof.T, self.nLevels, extent=extentYPY, \ origin = 'lower') if self.doScatter == True and len(xyScatter['y']) != 0: plt.scatter(xyScatter['x'], xyScatter['y'], \ s=dSize, c=myColor, marker='.', edgecolor='none') plt.xlim(-xLimHist, xLimHist) plt.ylim(-yLimHist, yLimHist) plt.xlabel(r'$x$') plt.ylabel(r'$y$')
As a result, it turns out that the obtained graphs apply to all scatter points that may exceed the limits for the contour graph. Is there any way around this?
source share