From: Sean L. <ody...@gm...> - 2015-05-26 17:07:08
|
Hello all, I'm using matplotlib 1.4.3 installed using fink with python 2.7. I'm trying to produce a grid of plots using gridspec that has annotations to label each plot. Here is the call to annotate the current axes: ax.annotate( r"$\mathbf{" + lab + ")}$", xy=(0.5*(xmin+xmax), 0.5*(ymin+ymax)), xytext=(0.9, 0.9), textcoords="axes fraction", fontsize=14 ) Where ax is initialized by: ax = plt.subplot(gs[ coords[0], coords[1] ]) and gs by: gs = mpgs.GridSpec( 3, 2, wspace=0.0, hspace=0.0 ) The trouble comes in when abs(ymax) < abs(ymin). When that is true, the labels are offset upward by one row, for some reason. I've attached a script that demonstrates the problem, and an example of the output. I can work around this problem by using "data" coordinates, but even so this reveals a bug somewhere. Thanks, Sean Lake |