On Thu, Feb 2, 2012 at 8:52 AM, Fabien Lafont <lafont.fab...@gmail.com> wrote: > I don't manage to put the color of my plot in the argument' list function. > > Example: > > def function(color): > > plot(x,y,'.', color, label = "this is my curve") > > > function('r') > > even if I put function(" 'r' ") it doesn't work. > > Any idea?
I would suggest using named arguments for everything other than x and y, so plot(x,y,marker=',', color=color, label='this is my curve') http://matplotlib.sourceforge.net/api/axes_api.html?highlight=plot#matplotlib.axes.Axes.plot daryl ------------------------------------------------------------------------------ Keep Your Developer Skills Current with LearnDevNow! The most comprehensive online learning library for Microsoft developers is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, Metro Style Apps, more. Free future releases when you subscribe now! http://p.sf.net/sfu/learndevnow-d2d _______________________________________________ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users