python - Transparent markerfacecolor in Matplotlib -


i plot bunch of markers (one @ time) have semi-transparent face color , opaque (alpha=1) edge color using matplotlib. seemed straight forward set each in plot command using appropriate rgba values (like suggested in this answer), it's not working sample code (updated original post better illustrate issue):

n = 48 xys = np.random.rand(n,2) markers = [] fig = plt.figure() ax = fig.add_subplot(111) in range(n):     m = ax.plot(         xys[i,0], xys[i,1],         linestyle='none', marker='o', markersize=20,         markeredgewidth=4, markeredgecolor=(0, 0, 0, 1.0),         markerfacecolor=(1, 0, 0.2, 0.1),     )[0] ax.grid() ax.set_axisbelow(true) fig.savefig('scratch_fig.png', dpi=300) 

that gives me plot: http://imgur.com/pccqlsv

as can see edges correct, solid black. but, when @ markers overlapping each other , grid can see not semi-transparent.

i produced result using matplotlib 1.2.1 on both windows 7 , ubuntu

does know how fix this, without creating 2 sets of overlapping markers?


Comments

Popular posts from this blog

How to mention the localhost in android -

php - Calling a template part from a post -

c# - String.format() DateTime With Arabic culture -