Hi diedro, try something like this:
import matplotlib.patches as patches import matplotlib.pyplot as plt fig = plt.figure() ax = fig.add_subplot(111) verts = [0.2,0.8], [0.1,0.5], [0.7,0.1] poly = patches.Polygon(verts, ec='r', fc='g') ax.add_patch(poly) plt.show() <http://matplotlib.1069221.n5.nabble.com/file/n44560/help3.png> or this: import numpy as np import matplotlib matplotlib.use('Agg') from matplotlib.patches import Polygon from matplotlib.collections import PatchCollection import matplotlib.pyplot as plt fig, ax = plt.subplots() patches = [] x = np.random.rand(3) y = np.random.rand(3) for i in range(3): polygon = Polygon(np.random.rand(3,2), True) patches.append(polygon) colors = 100*np.random.rand(len(patches)) p = PatchCollection(patches, cmap=matplotlib.cm.jet, alpha=0.4) p.set_array(np.array(colors)) ax.add_collection(p) plt.colorbar(p) plt.grid() plt.savefig('/var/www/img/help2.png', bbox_inches='tight',pad_inches=0.05) <http://matplotlib.1069221.n5.nabble.com/file/n44560/help2.png> Regards, Sappy85 -- View this message in context: http://matplotlib.1069221.n5.nabble.com/Patch-facecolors-tp44558p44560.html Sent from the matplotlib - users mailing list archive at Nabble.com. ------------------------------------------------------------------------------ Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server from Actuate! Instantly Supercharge Your Business Reports and Dashboards with Interactivity, Sharing, Native Excel Exports, App Integration & more Get technology previously reserved for billion-dollar corporations, FREE http://pubads.g.doubleclick.net/gampad/clk?id=164703151&iu=/4140/ostg.clktrk _______________________________________________ Matplotlib-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/matplotlib-users