[matplotlib-devel] Plot or Not: voting to create better matplotlibrc

2013-07-20 Thread David P. Sanders
Hi,

Probably many of you know about "Plot or Not", a site where we vote on the
same plot presented in different ways, to get feedback about better
matplotlibrc params:

http://warm-escarpment-9042.herokuapp.com/

It seems to me an absolutely fantastic idea! I think many people do not
realise how fantastic the plots can look with some of this modern styling.
(Styling was mentioned several times at SciPy.)

Would it be possible to put a link to this site on the matplotlib web page
and encourage people to use it?

Definitely time to update the defaults!!

Best wishes,
David.

-- 
Dr. David P. Sanders

Profesor Titular "A" / Associate Professor
Departamento de Física, Facultad de Ciencias
Universidad Nacional Autónoma de México (UNAM)

dpsand...@ciencias.unam.mx
http://sistemas.fciencias.unam.mx/~dsanders

Cubículo / office: #414, 4o. piso del Depto. de Física

Tel.: +52 55 5622 4965
--
See everything from the browser to the database with AppDynamics
Get end-to-end visibility with application monitoring from AppDynamics
Isolate bottlenecks and diagnose root cause in seconds.
Start your free trial of AppDynamics Pro today!
http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk___
Matplotlib-devel mailing list
Matplotlib-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel


[matplotlib-devel] How to use STIX fonts in matplotlib plots?

2013-07-20 Thread David P. Sanders
I find the default font used in matplotlib horrible. We should be able to
do much better these days.

One very interesting option, at least for standard (paper) publishing, is
the STIX fonts, which is a Times-like font set promoted by several
publishers.

There are various options in matplotlib, such as
matplotlib.rcParams["mathtext.fontset"], which allow the option "stix", but
I have not been able to get it to work. Can anybody please help me with
this -- what is required?

I have the STIX otf or ttf installed on my Mac, but I don't seem to manage
to get the LaTeX versions installed -- installing LaTeX fonts is *so*
disgusting (is there some helper script for that?).

Thanks and best wishes,
David.

-- 
Dr. David P. Sanders

Profesor Titular "A" / Associate Professor
Departamento de Física, Facultad de Ciencias
Universidad Nacional Autónoma de México (UNAM)

dpsand...@ciencias.unam.mx
http://sistemas.fciencias.unam.mx/~dsanders

Cubículo / office: #414, 4o. piso del Depto. de Física

Tel.: +52 55 5622 4965
--
See everything from the browser to the database with AppDynamics
Get end-to-end visibility with application monitoring from AppDynamics
Isolate bottlenecks and diagnose root cause in seconds.
Start your free trial of AppDynamics Pro today!
http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk___
Matplotlib-devel mailing list
Matplotlib-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel


Re: [matplotlib-devel] How to use STIX fonts in matplotlib plots?

2013-07-20 Thread David P. Sanders
Example script for using mathtext.fontset:

import matplotlib as mpl
import numpy as np
from matplotlib import pyplot as plt

mpl.rcParams["mathtext.fontset"] = "stix"

x = np.arange(-5, 5, 0.01)
y = x*x

plt.plot(x, y)
plt.xlabel(r"$x$")
plt.ylabel(r"$x^2$")
plt.show()

Apparently the axis labels are correctly rendered using STIX fonts, *but*
in a bitmapped way (?). At least, on my retina screen the labels look fuzzy.

How can I change also the tic labels to use STIX fonts?

By the way, the following is a useful idiom to search for relevant
parameters in the rcParams:

[k for k in mpl.rcParams.keys() if 'font' in k]

I think it would be useful to document this -- where would be a good place?

Finally, could somebody please explain what 'rc' means? This does not seem
like a good name to me.
I know it comes from the UNIX world, but I couldn't find an explanation for
'rc' on Wikipedia.

OK, I found it:
http://www.catb.org/jargon/html/R/rc-file.html

This is not good -- there is *no* reason to use the nomenclature 'rc'; this
is just confusing for users who find it arcane and unwelcoming (I speak
from experience).

Could it not just be called
mpl.parameters,   or  mpl.mpl_parameters,
or something like that?


Best,
David






On Sat, Jul 20, 2013 at 9:41 AM, David P. Sanders <
dpsand...@ciencias.unam.mx> wrote:

> I find the default font used in matplotlib horrible. We should be able to
> do much better these days.
>
> One very interesting option, at least for standard (paper) publishing, is
> the STIX fonts, which is a Times-like font set promoted by several
> publishers.
>
> There are various options in matplotlib, such as
> matplotlib.rcParams["mathtext.fontset"], which allow the option "stix",
> but I have not been able to get it to work. Can anybody please help me with
> this -- what is required?
>
> I have the STIX otf or ttf installed on my Mac, but I don't seem to manage
> to get the LaTeX versions installed -- installing LaTeX fonts is *so*
> disgusting (is there some helper script for that?).
>
> Thanks and best wishes,
> David.
>
> --
> Dr. David P. Sanders
>
> Profesor Titular "A" / Associate Professor
> Departamento de Física, Facultad de Ciencias
> Universidad Nacional Autónoma de México (UNAM)
>
> dpsand...@ciencias.unam.mx
> http://sistemas.fciencias.unam.mx/~dsanders
>
> Cubículo / office: #414, 4o. piso del Depto. de Física
>
> Tel.: +52 55 5622 4965
>



-- 
Dr. David P. Sanders

Profesor Titular "A" / Associate Professor
Departamento de Física, Facultad de Ciencias
Universidad Nacional Autónoma de México (UNAM)

dpsand...@ciencias.unam.mx
http://sistemas.fciencias.unam.mx/~dsanders

Cubículo / office: #414, 4o. piso del Depto. de Física

Tel.: +52 55 5622 4965
--
See everything from the browser to the database with AppDynamics
Get end-to-end visibility with application monitoring from AppDynamics
Isolate bottlenecks and diagnose root cause in seconds.
Start your free trial of AppDynamics Pro today!
http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk___
Matplotlib-devel mailing list
Matplotlib-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel


Re: [matplotlib-devel] Plot or Not: voting to create better matplotlibrc

2013-07-20 Thread Eric Firing
On 2013/07/20 4:18 AM, David P. Sanders wrote:
> Hi,
>
> Probably many of you know about "Plot or Not", a site where we vote on
> the same plot presented in different ways, to get feedback about better
> matplotlibrc params:
>
> http://warm-escarpment-9042.herokuapp.com/
>
> It seems to me an absolutely fantastic idea! I think many people do not
> realise how fantastic the plots can look with some of this modern
> styling. (Styling was mentioned several times at SciPy.)
>
> Would it be possible to put a link to this site on the matplotlib web
> page and encourage people to use it?

David,

Interesting, but I'm not sure this is a good approach.  I really don't 
see the point of the voting.  What I think would be more useful would be 
a set of matplotlibrc files with examples of their effect on at least a 
few plot types.

>
> Definitely time to update the defaults!!

Or maybe include a representative set of rcParams combinations to make 
it easier for people to choose a design that suits their purpose.  This 
could be part of a toolkit.

Eric

>
> Best wishes,
> David.
>
> --
> Dr. David P. Sanders
>
> Profesor Titular "A" / Associate Professor
> Departamento de Física, Facultad de Ciencias
> Universidad Nacional Autónoma de México (UNAM)
>
> dpsand...@ciencias.unam.mx 
> http://sistemas.fciencias.unam.mx/~dsanders
> 
>
> Cubículo / office: #414, 4o. piso del Depto. de Física
> Tel.: +52 55 5622 4965
>
>
> --
> See everything from the browser to the database with AppDynamics
> Get end-to-end visibility with application monitoring from AppDynamics
> Isolate bottlenecks and diagnose root cause in seconds.
> Start your free trial of AppDynamics Pro today!
> http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk
>
>
>
> ___
> Matplotlib-devel mailing list
> Matplotlib-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/matplotlib-devel
>


--
See everything from the browser to the database with AppDynamics
Get end-to-end visibility with application monitoring from AppDynamics
Isolate bottlenecks and diagnose root cause in seconds.
Start your free trial of AppDynamics Pro today!
http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk
___
Matplotlib-devel mailing list
Matplotlib-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel


Re: [matplotlib-devel] How to use STIX fonts in matplotlib plots?

2013-07-20 Thread Eric Firing
On 2013/07/20 4:41 AM, David P. Sanders wrote:
> I find the default font used in matplotlib horrible. We should be able
> to do much better these days.

Which font is being used as default on your installation?  And what are 
the characteristics that earn the rating of "horrible"?

Eric

--
See everything from the browser to the database with AppDynamics
Get end-to-end visibility with application monitoring from AppDynamics
Isolate bottlenecks and diagnose root cause in seconds.
Start your free trial of AppDynamics Pro today!
http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk
___
Matplotlib-devel mailing list
Matplotlib-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel


Re: [matplotlib-devel] Plot or Not: voting to create better matplotlibrc

2013-07-20 Thread Benjamin Root
>From discussions with others at SciPy, we found ourselves disagreeing on
what default we would want. We also weren't sure exactly which params were
the ones that people tended to change. We have zero data on this. This site
is intended to help start that data collection process.

We can certainly improve this site to collect other kinds of info, but this
is just a start. One could also view this as a launching point for teaching
how to use rcParams (sorry David, i kinda like that name) in mpl. You all
know I never let a good teaching moment go to waste!

As for linking from matplotlib.org, I am ambivalent. It is a bit gimmicky,
and I do worry about being counterproductive to efforts in SciPy to be more
inclusive of women (given the rather anti-feministic undertones of the site
we are parodying). Of course, that could just be me being overly cautious.

Cheers!
Ben Root
On Jul 20, 2013 2:20 PM, "Eric Firing"  wrote:

> On 2013/07/20 4:18 AM, David P. Sanders wrote:
> > Hi,
> >
> > Probably many of you know about "Plot or Not", a site where we vote on
> > the same plot presented in different ways, to get feedback about better
> > matplotlibrc params:
> >
> > http://warm-escarpment-9042.herokuapp.com/
> >
> > It seems to me an absolutely fantastic idea! I think many people do not
> > realise how fantastic the plots can look with some of this modern
> > styling. (Styling was mentioned several times at SciPy.)
> >
> > Would it be possible to put a link to this site on the matplotlib web
> > page and encourage people to use it?
>
> David,
>
> Interesting, but I'm not sure this is a good approach.  I really don't
> see the point of the voting.  What I think would be more useful would be
> a set of matplotlibrc files with examples of their effect on at least a
> few plot types.
>
> >
> > Definitely time to update the defaults!!
>
> Or maybe include a representative set of rcParams combinations to make
> it easier for people to choose a design that suits their purpose.  This
> could be part of a toolkit.
>
> Eric
>
> >
> > Best wishes,
> > David.
> >
> > --
> > Dr. David P. Sanders
> >
> > Profesor Titular "A" / Associate Professor
> > Departamento de Física, Facultad de Ciencias
> > Universidad Nacional Autónoma de México (UNAM)
> >
> > dpsand...@ciencias.unam.mx 
> > http://sistemas.fciencias.unam.mx/~dsanders
> > 
> >
> > Cubículo / office: #414, 4o. piso del Depto. de Física
> > Tel.: +52 55 5622 4965
> >
> >
> >
> --
> > See everything from the browser to the database with AppDynamics
> > Get end-to-end visibility with application monitoring from AppDynamics
> > Isolate bottlenecks and diagnose root cause in seconds.
> > Start your free trial of AppDynamics Pro today!
> >
> http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk
> >
> >
> >
> > ___
> > Matplotlib-devel mailing list
> > Matplotlib-devel@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/matplotlib-devel
> >
>
>
>
> --
> See everything from the browser to the database with AppDynamics
> Get end-to-end visibility with application monitoring from AppDynamics
> Isolate bottlenecks and diagnose root cause in seconds.
> Start your free trial of AppDynamics Pro today!
> http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk
> ___
> Matplotlib-devel mailing list
> Matplotlib-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/matplotlib-devel
>
--
See everything from the browser to the database with AppDynamics
Get end-to-end visibility with application monitoring from AppDynamics
Isolate bottlenecks and diagnose root cause in seconds.
Start your free trial of AppDynamics Pro today!
http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk___
Matplotlib-devel mailing list
Matplotlib-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel


Re: [matplotlib-devel] How to use STIX fonts in matplotlib plots?

2013-07-20 Thread Benjamin Root
David,

IIRC, we were just starting to investigate how to produce retina graphics.
Perhaps you might be able to help Mike D and Michael de Hoon with there
efforts because very few of us have retina displays.

Cheers!
Ben Root
On Jul 20, 2013 10:43 AM, "David P. Sanders" 
wrote:

> I find the default font used in matplotlib horrible. We should be able to
> do much better these days.
>
> One very interesting option, at least for standard (paper) publishing, is
> the STIX fonts, which is a Times-like font set promoted by several
> publishers.
>
> There are various options in matplotlib, such as
> matplotlib.rcParams["mathtext.fontset"], which allow the option "stix",
> but I have not been able to get it to work. Can anybody please help me with
> this -- what is required?
>
> I have the STIX otf or ttf installed on my Mac, but I don't seem to manage
> to get the LaTeX versions installed -- installing LaTeX fonts is *so*
> disgusting (is there some helper script for that?).
>
> Thanks and best wishes,
> David.
>
> --
> Dr. David P. Sanders
>
> Profesor Titular "A" / Associate Professor
> Departamento de Física, Facultad de Ciencias
> Universidad Nacional Autónoma de México (UNAM)
>
> dpsand...@ciencias.unam.mx
> http://sistemas.fciencias.unam.mx/~dsanders
>
> Cubículo / office: #414, 4o. piso del Depto. de Física
>
> Tel.: +52 55 5622 4965
>
>
> --
> See everything from the browser to the database with AppDynamics
> Get end-to-end visibility with application monitoring from AppDynamics
> Isolate bottlenecks and diagnose root cause in seconds.
> Start your free trial of AppDynamics Pro today!
> http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk
> ___
> Matplotlib-devel mailing list
> Matplotlib-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/matplotlib-devel
>
>
--
See everything from the browser to the database with AppDynamics
Get end-to-end visibility with application monitoring from AppDynamics
Isolate bottlenecks and diagnose root cause in seconds.
Start your free trial of AppDynamics Pro today!
http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk___
Matplotlib-devel mailing list
Matplotlib-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel


Re: [matplotlib-devel] Plot or Not: voting to create better matplotlibrc

2013-07-20 Thread Eric Firing
On 2013/07/20 8:58 AM, Benjamin Root wrote:
>  From discussions with others at SciPy, we found ourselves disagreeing
> on what default we would want. We also weren't sure exactly which params
> were the ones that people tended to change. We have zero data on this.
> This site is intended to help start that data collection process.

Then it might help to add some introductory info to the page.  When I 
went to it, all I saw was two versions of a plot and 3 buttons.  That 
was not enough to motivate me to go further, so I don't know what would 
have happened if I had clicked one of the buttons.

>
> We can certainly improve this site to collect other kinds of info, but
> this is just a start. One could also view this as a launching point for
> teaching how to use rcParams (sorry David, i kinda like that name) in
> mpl. You all know I never let a good teaching moment go to waste!

Maybe the teaching would happen after clicking one of the buttons; it 
certainly was not apparent to me from the first page that there was a 
prospect of learning something.

>
> As for linking from matplotlib.org , I am
> ambivalent. It is a bit gimmicky, and I do worry about being
> counterproductive to efforts in SciPy to be more inclusive of women
> (given the rather anti-feministic undertones of the site we are
> parodying). Of course, that could just be me being overly cautious.

What site are you parodying?  On second thought, it sounds like it would 
be better if I remain ignorant; and I suspect you are not being overly 
cautious in having some reservations.

Eric

>
> Cheers!
> Ben Root
>
> On Jul 20, 2013 2:20 PM, "Eric Firing"  > wrote:
>
> On 2013/07/20 4:18 AM, David P. Sanders wrote:
>  > Hi,
>  >
>  > Probably many of you know about "Plot or Not", a site where we
> vote on
>  > the same plot presented in different ways, to get feedback about
> better
>  > matplotlibrc params:
>  >
>  > http://warm-escarpment-9042.herokuapp.com/
>  >
>  > It seems to me an absolutely fantastic idea! I think many people
> do not
>  > realise how fantastic the plots can look with some of this modern
>  > styling. (Styling was mentioned several times at SciPy.)
>  >
>  > Would it be possible to put a link to this site on the matplotlib web
>  > page and encourage people to use it?
>
> David,
>
> Interesting, but I'm not sure this is a good approach.  I really don't
> see the point of the voting.  What I think would be more useful would be
> a set of matplotlibrc files with examples of their effect on at least a
> few plot types.
>
>  >
>  > Definitely time to update the defaults!!
>
> Or maybe include a representative set of rcParams combinations to make
> it easier for people to choose a design that suits their purpose.  This
> could be part of a toolkit.
>
> Eric
>
>  >
>  > Best wishes,
>  > David.
>  >
>  > --
>  > Dr. David P. Sanders
>  >
>  > Profesor Titular "A" / Associate Professor
>  > Departamento de Física, Facultad de Ciencias
>  > Universidad Nacional Autónoma de México (UNAM)
>  >
>  > dpsand...@ciencias.unam.mx 
> >
>  > http://sistemas.fciencias.unam.mx/~dsanders
>  > 
>  >
>  > Cubículo / office: #414, 4o. piso del Depto. de Física
>  > Tel.: +52 55 5622 4965 
>  >
>  >
>  >
> 
> --
>  > See everything from the browser to the database with AppDynamics
>  > Get end-to-end visibility with application monitoring from
> AppDynamics
>  > Isolate bottlenecks and diagnose root cause in seconds.
>  > Start your free trial of AppDynamics Pro today!
>  >
> 
> http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk
>  >
>  >
>  >
>  > ___
>  > Matplotlib-devel mailing list
>  > Matplotlib-devel@lists.sourceforge.net
> 
>  > https://lists.sourceforge.net/lists/listinfo/matplotlib-devel
>  >
>
>
> 
> --
> See everything from the browser to the database with AppDynamics
> Get end-to-end visibility with application monitoring from AppDynamics
> Isolate bottlenecks and diagnose root cause in seconds.
> Start your free trial of AppDynamics Pro today!
> 
> http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk
> ___
> Matplotlib-devel mailing list
> Matplotlib-devel@lists.sourceforge.net
> 

Re: [matplotlib-devel] Plot or Not: voting to create better matplotlibrc

2013-07-20 Thread Chris Beaumont
Hi,

I thought I'd chime in on this discussion -- Adrian Price-Whelan and I put
together plotornot during the SciPy sprints.

I wouldn't advocate for linking to plotornot from matplotlib -- the idea is
semi tongue-in-cheek, and meant to gauge to what extent there is consensus
about plot styles. It's not set up to teach about rcParams, nor does it
systematically explore all possible styles. The votes (>10K, last I
checked) are saved, and eventually Adrian or I will look over the feedback
and report back to you all. I haven't had time for that yet. I hope the
name didn't *actually* offend anyone.

At the risk of sounding unappreciative of MPL (which I love, and rely upon
daily), I must admit I was disheartened after hearing the MPL devs at SciPy
discuss styles and defaults. I understand that you don't want to change the
default styles without a clearly better alternative. I also understand
that, to some extent, style preferences are subjective. However, there
seemed to be quite a bit of resistance to the idea that MPL defaults should
change *at all.*

Even if you ignore the subjective component of this (which I think is a
mistake, since in my experience there is broad consensus that projects like
ggplot2, d3, tableau, and spotfire do a "better" job than MPL at styling),
there are some well-established visual principles that matplotlib violates.
Some of my biggest pet peeves are:

1) The default 'axes.color_cycle' values should be equally visible, with
similar luminance values. The current defaults (bgrcmyk) do not have this
property -- c and y are harder to see, and thus carry less visual emphasis.
A color table like the "Dark2" color brewer table (
http://learnr.files.wordpress.com/2009/04/colours-dark2.png,
colorbrewer2.org) is more uniform, and carefully designed for visibility
and contrast. 'rgbcmyk' is clearly an arbitrary choice -- why not use a
smarter default?

2) The default 'jet' colormap for images has a lot of poor properties
(which is even mentioned on the MPL docs at
http://matplotlib.org/api/pyplot_summary.html#id1). The brain is bad at
ordering changes in hue (which is bigger -- purple or yellow?), and better
at ordering changes in intensity or saturation. A colleague of mine
designed a visualization tool for doctors, and found that the rainbow color
table had a dramatic negative effect on the effectiveness of the tool (you
can watch her TED talk about this at
https://www.youtube.com/watch?v=kU7veyGGps4&t=440s). The jet default is
especially frustrating, since it *cannot* be modified via rcParams

3) Some of the defaults violate Tufte principles like minimizing "chart
junk." For example, the 'stepfilled' mode for hist is probably better than
the default, which draws vertical lines between every bin. Those lines make
the histogram noisier -- do they convey any extra information? Again, this
can't be tweaked via rcParams.

Sorry for being long-winded -- I just want to make the case that this is an
important (and not *entirely* subjective) issue. If nothing else, it would
be great to see some clear statement about where the MPL devs stand on this
issue -- what criteria must be met to consider a change to the defaults? My
apologies if such a document already exists somewhere!

Cheers,
Chris Beaumont





On Sat, Jul 20, 2013 at 3:03 PM, <
matplotlib-devel-requ...@lists.sourceforge.net> wrote:

> Send Matplotlib-devel mailing list submissions to
> matplotlib-devel@lists.sourceforge.net
>
> To subscribe or unsubscribe via the World Wide Web, visit
> https://lists.sourceforge.net/lists/listinfo/matplotlib-devel
> or, via email, send a message with subject or body 'help' to
> matplotlib-devel-requ...@lists.sourceforge.net
>
> You can reach the person managing the list at
> matplotlib-devel-ow...@lists.sourceforge.net
>
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of Matplotlib-devel digest..."
>
>
> Today's Topics:
>
>1. Re: Plot or Not: voting to create better  matplotlibrc
>   (Eric Firing)
>2. Re: How to use STIX fonts in matplotlib plots? (Eric Firing)
>3. Re: Plot or Not: voting to create better  matplotlibrc
>   (Benjamin Root)
>4. Re: How to use STIX fonts in matplotlib plots? (Benjamin Root)
>
>
> --
>
> Message: 1
> Date: Sat, 20 Jul 2013 08:20:11 -1000
> From: Eric Firing 
> Subject: Re: [matplotlib-devel] Plot or Not: voting to create better
> matplotlibrc
> To: matplotlib-devel@lists.sourceforge.net
> Message-ID: <51ead4db.5040...@hawaii.edu>
> Content-Type: text/plain; charset=ISO-8859-1; format=flowed
>
> On 2013/07/20 4:18 AM, David P. Sanders wrote:
> > Hi,
> >
> > Probably many of you know about "Plot or Not", a site where we vote on
> > the same plot presented in different ways, to get feedback about better
> > matplotlibrc params:
> >
> > http://warm-escarpment-9042.herokuapp.com/
> >
> > It seems to me an 

Re: [matplotlib-devel] Plot or Not: voting to create better matplotlibrc

2013-07-20 Thread Adrian Price-Whelan
Hi,

Definitely don't link from matplotlib. This was a fun hack put together to
get people talking about re-styling -- success!

I have to echo Chris' disappointment about the discussion of defaults in
MPL. While there are certainly many subjective elements of style and
design, there are also a number of rules that the default settings violate
(as Chris mentions below). The way I interpret the push-back to replacing
the defaults is: "there are too many better alternatives that we will never
agree upon, so let's just keep what's there." To 0th order, just pick one!
Fixing the few things that Chris mentions below will go a long way to
modernizing the MPL feel and experience. There many other things I would
like to change about the defaults, but maybe the right thing to do is just
issue a pull request so we can discuss on there?

As a longer term idea, I propose:
- normalize what can and can't be modified with an rc file -- right now,
it's kind of all over the place

then:
- each plot in the matplotlib gallery should have a drop-down menu with
~3-5 style options
- these options can be named or whatever, but should be complete
matplotlibrc files that can either be a) shipped with matplotlib, or b)
very easily downloaded and installed (think:
 matplotlib.rc_install('name-of-style'))
- on each gallery entry page, selecting an option from the drop-down should
show the same plot made with the specified rc style

I'm happy to help implement this stuff, but I think this would be a
tremendous resource to the community.

And if you decide to reject everything from this email, *please* at least
change the default colormap :) #downwithJet

- Adrian

From: Chris Beaumont 
> Date: Sat, Jul 20, 2013 at 5:47 PM
> Subject: Re: Plot or Not: voting to create better matplotlibrc
> To: matplotlib-devel@lists.sourceforge.net
>
>
> Hi,
>
> I thought I'd chime in on this discussion -- Adrian Price-Whelan and I put
> together plotornot during the SciPy sprints.
>
> I wouldn't advocate for linking to plotornot from matplotlib -- the idea
> is semi tongue-in-cheek, and meant to gauge to what extent there is
> consensus about plot styles. It's not set up to teach about rcParams, nor
> does it systematically explore all possible styles. The votes (>10K, last I
> checked) are saved, and eventually Adrian or I will look over the feedback
> and report back to you all. I haven't had time for that yet. I hope the
> name didn't *actually* offend anyone.
>
> At the risk of sounding unappreciative of MPL (which I love, and rely upon
> daily), I must admit I was disheartened after hearing the MPL devs at SciPy
> discuss styles and defaults. I understand that you don't want to change the
> default styles without a clearly better alternative. I also understand
> that, to some extent, style preferences are subjective. However, there
> seemed to be quite a bit of resistance to the idea that MPL defaults should
> change *at all.*
>
> Even if you ignore the subjective component of this (which I think is a
> mistake, since in my experience there is broad consensus that projects like
> ggplot2, d3, tableau, and spotfire do a "better" job than MPL at styling),
> there are some well-established visual principles that matplotlib violates.
> Some of my biggest pet peeves are:
>
> 1) The default 'axes.color_cycle' values should be equally visible, with
> similar luminance values. The current defaults (bgrcmyk) do not have this
> property -- c and y are harder to see, and thus carry less visual emphasis.
> A color table like the "Dark2" color brewer table (
> http://learnr.files.wordpress.com/2009/04/colours-dark2.png,
> colorbrewer2.org) is more uniform, and carefully designed for visibility
> and contrast. 'rgbcmyk' is clearly an arbitrary choice -- why not use a
> smarter default?
>
> 2) The default 'jet' colormap for images has a lot of poor properties
> (which is even mentioned on the MPL docs at
> http://matplotlib.org/api/pyplot_summary.html#id1). The brain is bad at
> ordering changes in hue (which is bigger -- purple or yellow?), and better
> at ordering changes in intensity or saturation. A colleague of mine
> designed a visualization tool for doctors, and found that the rainbow color
> table had a dramatic negative effect on the effectiveness of the tool (you
> can watch her TED talk about this at
> https://www.youtube.com/watch?v=kU7veyGGps4&t=440s). The jet default is
> especially frustrating, since it *cannot* be modified via rcParams
>
> 3) Some of the defaults violate Tufte principles like minimizing "chart
> junk." For example, the 'stepfilled' mode for hist is probably better than
> the default, which draws vertical lines between every bin. Those lines make
> the histogram noisier -- do they convey any extra information? Again, this
> can't be tweaked via rcParams.
>
> Sorry for being long-winded -- I just want to make the case that this is
> an important (and not *entirely* subjective) issue. If nothing else, it
> would be great to see some

Re: [matplotlib-devel] Plot or Not: voting to create better matplotlibrc

2013-07-20 Thread Eric Firing
On 2013/07/20 11:47 AM, Chris Beaumont wrote:
> Hi,
>
> I thought I'd chime in on this discussion -- Adrian Price-Whelan and I
> put together plotornot during the SciPy sprints.
>
> I wouldn't advocate for linking to plotornot from matplotlib -- the idea
> is semi tongue-in-cheek, and meant to gauge to what extent there is
> consensus about plot styles. It's not set up to teach about rcParams,
> nor does it systematically explore all possible styles. The votes (>10K,
> last I checked) are saved, and eventually Adrian or I will look over the
> feedback and report back to you all. I haven't had time for that yet. I
> hope the name didn't *actually* offend anyone.
>
> At the risk of sounding unappreciative of MPL (which I love, and rely
> upon daily), I must admit I was disheartened after hearing the MPL devs
> at SciPy discuss styles and defaults. I understand that you don't want
> to change the default styles without a clearly better alternative. I
> also understand that, to some extent, style preferences are subjective.
> However, there seemed to be quite a bit of resistance to the idea that
> MPL defaults should change *at all.*
>
> Even if you ignore the subjective component of this (which I think is a
> mistake, since in my experience there is broad consensus that projects
> like ggplot2, d3, tableau, and spotfire do a "better" job than MPL at
> styling), there are some well-established visual principles that
> matplotlib violates. Some of my biggest pet peeves are:
>
> 1) The default 'axes.color_cycle' values should be equally visible, with
> similar luminance values. The current defaults (bgrcmyk) do not have
> this property -- c and y are harder to see, and thus carry less visual
> emphasis. A color table like the "Dark2" color brewer table
> (http://learnr.files.wordpress.com/2009/04/colours-dark2.png,
> colorbrewer2.org ) is more uniform, and
> carefully designed for visibility and contrast. 'rgbcmyk' is clearly an
> arbitrary choice -- why not use a smarter default?
>
> 2) The default 'jet' colormap for images has a lot of poor properties
> (which is even mentioned on the MPL docs at
> http://matplotlib.org/api/pyplot_summary.html#id1). The brain is bad at
> ordering changes in hue (which is bigger -- purple or yellow?), and
> better at ordering changes in intensity or saturation. A colleague of
> mine designed a visualization tool for doctors, and found that the
> rainbow color table had a dramatic negative effect on the effectiveness
> of the tool (you can watch her TED talk about this at
> https://www.youtube.com/watch?v=kU7veyGGps4&t=440s). The jet default is
> especially frustrating, since it *cannot* be modified via rcParams
>
> 3) Some of the defaults violate Tufte principles like minimizing "chart
> junk." For example, the 'stepfilled' mode for hist is probably better
> than the default, which draws vertical lines between every bin. Those
> lines make the histogram noisier -- do they convey any extra
> information? Again, this can't be tweaked via rcParams.
>
> Sorry for being long-winded -- I just want to make the case that this is
> an important (and not *entirely* subjective) issue. If nothing else, it
> would be great to see some clear statement about where the MPL devs
> stand on this issue -- what criteria must be met to consider a change to
> the defaults? My apologies if such a document already exists somewhere!
>
> Cheers,
> Chris Beaumont

Chris,

I appreciate the ideas, and I agree entirely that improvements are in 
order, so it is just a question of exactly what and how, not whether 
there should be changes.  (For example, the default line color set often 
irritates me, too, because blue and green look rather similar, 
particularly in comparison to red, which visually overwhelms the others.)

A problem with simply changing the defaults to some sort of consensus or 
majority opinion as to what is better is that inevitably there will be 
users who will be distressed when they upgrade and suddenly find that 
all their plots--perhaps generated automatically by their cron jobs or 
web apps--look very different, and perhaps don't even work well with the 
new defaults.  Therefore we have to be somewhat conservative, and the 
tendency is to minimize changes that are not essential.  I think that a 
change in the defaults will need to be staged in such a fashion that it 
will be as easy as possible for users to retain the old defaults if they 
prefer them.  That leads to the idea that something like a style toolkit 
or cookbook, or set of examples included with mpl, might be helpful. 
There is never going to be one good style for all; it would be good to 
have examples of how to tailor things for the screen, or for paper, or 
for presentations, or for publications (some of which still favor black 
and white).

The mpl examples (gallery) can be the first target for improvement; 
based on some experience and input, an actual change in the defaults 
might be announc

Re: [matplotlib-devel] Plot or Not: voting to create better matplotlibrc

2013-07-20 Thread Eric Firing
On 2013/07/20 2:38 PM, David P. Sanders wrote:
> And this is my problem with 'rc':  it brings to mind an arcane config
> file hidden away somewhere that has a terrible syntax and must not be
> touched.
>
> As Chris and Adrian have emphasized, the point is that we *should* be
> tweaking away at the parameters all the time.
> I propose to rename as  mpl_params=rcParams
>

Yes, mpl_params is more descriptive and easy to remember.  rcParams is 
ugly, obscure, and archaic.  It will have to remain available for a long 
time, but I don't object to changing standard usage to a nicer name. 
There might even be a better name than "mpl_params"--"settings" comes to 
mind, or maybe "style".

As for parameter tweaking: the defaults shipped with mpl should be 
changed only rarely, but we should make it as easy as possible for users 
to customize plots, including coming up with good combinations of style 
parameters.  In some cases it makes sense to do this via a matplotlibrc 
file, in other cases it is better to do the parameter setting explicitly 
at the top of a script.

Regarding defaults, note that I said "rarely", not "never".

The whole rc system could use a good review--maybe resulting in lots of 
changes, maybe not--so I welcome the attention you are directing to it.

Eric

--
See everything from the browser to the database with AppDynamics
Get end-to-end visibility with application monitoring from AppDynamics
Isolate bottlenecks and diagnose root cause in seconds.
Start your free trial of AppDynamics Pro today!
http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk
___
Matplotlib-devel mailing list
Matplotlib-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel


Re: [matplotlib-devel] Plot or Not: voting to create better matplotlibrc

2013-07-20 Thread Tony Yu
On Sat, Jul 20, 2013 at 4:47 PM, Chris Beaumont  wrote:

> Hi,
>
> I thought I'd chime in on this discussion -- Adrian Price-Whelan and I put
> together plotornot during the SciPy sprints.
>
> I wouldn't advocate for linking to plotornot from matplotlib -- the idea
> is semi tongue-in-cheek, and meant to gauge to what extent there is
> consensus about plot styles. It's not set up to teach about rcParams, nor
> does it systematically explore all possible styles. The votes (>10K, last I
> checked) are saved, and eventually Adrian or I will look over the feedback
> and report back to you all. I haven't had time for that yet. I hope the
> name didn't *actually* offend anyone.
>
> At the risk of sounding unappreciative of MPL (which I love, and rely upon
> daily), I must admit I was disheartened after hearing the MPL devs at SciPy
> discuss styles and defaults. I understand that you don't want to change the
> default styles without a clearly better alternative. I also understand
> that, to some extent, style preferences are subjective. However, there
> seemed to be quite a bit of resistance to the idea that MPL defaults should
> change *at all.*
>
> Even if you ignore the subjective component of this (which I think is a
> mistake, since in my experience there is broad consensus that projects like
> ggplot2, d3, tableau, and spotfire do a "better" job than MPL at styling),
> there are some well-established visual principles that matplotlib violates.
> Some of my biggest pet peeves are:
>
> 1) The default 'axes.color_cycle' values should be equally visible, with
> similar luminance values. The current defaults (bgrcmyk) do not have this
> property -- c and y are harder to see, and thus carry less visual emphasis.
> A color table like the "Dark2" color brewer table (
> http://learnr.files.wordpress.com/2009/04/colours-dark2.png,
> colorbrewer2.org) is more uniform, and carefully designed for visibility
> and contrast. 'rgbcmyk' is clearly an arbitrary choice -- why not use a
> smarter default?
>
> 2) The default 'jet' colormap for images has a lot of poor properties
> (which is even mentioned on the MPL docs at
> http://matplotlib.org/api/pyplot_summary.html#id1). The brain is bad at
> ordering changes in hue (which is bigger -- purple or yellow?), and better
> at ordering changes in intensity or saturation. A colleague of mine
> designed a visualization tool for doctors, and found that the rainbow color
> table had a dramatic negative effect on the effectiveness of the tool (you
> can watch her TED talk about this at
> https://www.youtube.com/watch?v=kU7veyGGps4&t=440s). The jet default is
> especially frustrating, since it *cannot* be modified via rcParams
>

Jet is terrible for so many reasons, but it can be modified (unless I
misunderstand):

image.cmap : gray

I'm all for changing the current defaults.

Cheers,
-Tony
--
See everything from the browser to the database with AppDynamics
Get end-to-end visibility with application monitoring from AppDynamics
Isolate bottlenecks and diagnose root cause in seconds.
Start your free trial of AppDynamics Pro today!
http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk___
Matplotlib-devel mailing list
Matplotlib-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel


Re: [matplotlib-devel] Plot or Not: voting to create better matplotlibrc

2013-07-20 Thread Chris Beaumont
'image.cmap' -- nice! Shows how much I know :)

I don't fully agree with Eric that changing the defaults should be treated
as an API break -- yes, it may irritate a minority of users, but their code
will still run. I'd flip around your argument for the role of rcParams and
customization: the majority user is probably someone who doesn't know much
about rcParams, or all the ways plots can be customized. *That* is the use
case to optimize, not the "legacy" users invested in the current style.

However, default tweaking need not be painful. As has been mentioned, a
first step would be an easier way to change a whole set of rcParams:
something like mpl.set_style('style-name'). As long as one style is
'classic', users can keep the current style for as long as they want. It's
a one line fix, and could even be rcParams-settable.

With such a framework, it would be possible for people to contribute new
styles that ship with MPL, and users could change styles without having to
find (and potentially merge) rcParams files from the web. Finally, people
could nominate that mature styles be made default (you could even assign
version numbers to track the default style as it evolves towards visual
awesomeness)

chris



On Sat, Jul 20, 2013 at 9:07 PM, Eric Firing  wrote:

> On 2013/07/20 2:38 PM, David P. Sanders wrote:
> > And this is my problem with 'rc':  it brings to mind an arcane config
> > file hidden away somewhere that has a terrible syntax and must not be
> > touched.
> >
> > As Chris and Adrian have emphasized, the point is that we *should* be
> > tweaking away at the parameters all the time.
> > I propose to rename as  mpl_params=rcParams
> >
>
> Yes, mpl_params is more descriptive and easy to remember.  rcParams is
> ugly, obscure, and archaic.  It will have to remain available for a long
> time, but I don't object to changing standard usage to a nicer name.
> There might even be a better name than "mpl_params"--"settings" comes to
> mind, or maybe "style".
>
> As for parameter tweaking: the defaults shipped with mpl should be
> changed only rarely, but we should make it as easy as possible for users
> to customize plots, including coming up with good combinations of style
> parameters.  In some cases it makes sense to do this via a matplotlibrc
> file, in other cases it is better to do the parameter setting explicitly
> at the top of a script.
>
> Regarding defaults, note that I said "rarely", not "never".
>
> The whole rc system could use a good review--maybe resulting in lots of
> changes, maybe not--so I welcome the attention you are directing to it.
>
> Eric
>
>
> --
> See everything from the browser to the database with AppDynamics
> Get end-to-end visibility with application monitoring from AppDynamics
> Isolate bottlenecks and diagnose root cause in seconds.
> Start your free trial of AppDynamics Pro today!
> http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk
> ___
> Matplotlib-devel mailing list
> Matplotlib-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/matplotlib-devel
>



-- 

Chris Beaumont
Graduate Student
Institute for Astronomy
University of Hawaii at Manoa
2680 Woodlawn Drive
Honolulu, HI 96822
www.ifa.hawaii.edu/~beaumont

--
See everything from the browser to the database with AppDynamics
Get end-to-end visibility with application monitoring from AppDynamics
Isolate bottlenecks and diagnose root cause in seconds.
Start your free trial of AppDynamics Pro today!
http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk___
Matplotlib-devel mailing list
Matplotlib-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel


[matplotlib-devel] rcParams -> mpl_params

2013-07-20 Thread David P. Sanders
Hi,

Apparently I was misusing the list by having digests sent -- apologies.
I have turned this off.

Maybe the following got lost in the resulting noise:

I completely agree that the current defaults need updating.

In my opinion, 'rcParams' is a bad name, since it conjures up dusty
configuration files hidden in obscure corners which must never be modified.

Indeed, http://en.wikipedia.org/wiki/Run_commands says that the origin of
'rc' is:

> The term *rc* stands for the phrase "*run commands*". It is used for any
file that contains
> startup information for a command. It is believed to have originated
somewhere in 1965

None of these three 'features' of the phrase 'rc' have *anything*  to do
with matplotlib.
'rc' evokes fond memories of hacking for a few; it evokes nothing and reeks
of alienating hack-speak to the rest.

I thus suggest that we replace rc_Params -> mpl_params.

As an example, I have made some narrative documentation, which can be
included in the matplotlib documentation (let's discuss where, Nelle and
Mike), on how to tweak mpl_params:

http://nbviewer.ipython.org/urls/raw.github.com/dpsanders/IPython-notebooks/master/mpl_params.ipynb


This is, if you like, a cosmetic change, but I think it's an important
psychological one.
It also avoids the visual interruption caused by the capital 'P'.

Of course, anybody is free to make this change in the way I have in the
notebook by creating an alias, mpl_params = rcParams.  But I am advocating
for changing uniformly to mpl_params (or a similar phrase) in the
documentation.

David




-- 
Dr. David P. Sanders

Profesor Titular "A" / Associate Professor
Departamento de Física, Facultad de Ciencias
Universidad Nacional Autónoma de México (UNAM)

dpsand...@ciencias.unam.mx
http://sistemas.fciencias.unam.mx/~dsanders

Cubículo / office: #414, 4o. piso del Depto. de Física

Tel.: +52 55 5622 4965
--
See everything from the browser to the database with AppDynamics
Get end-to-end visibility with application monitoring from AppDynamics
Isolate bottlenecks and diagnose root cause in seconds.
Start your free trial of AppDynamics Pro today!
http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk___
Matplotlib-devel mailing list
Matplotlib-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel


Re: [matplotlib-devel] Plot or Not: voting to create better matplotlibrc

2013-07-20 Thread David P. Sanders
On Sat, Jul 20, 2013 at 8:48 PM, Chris Beaumont  wrote:

> 'image.cmap' -- nice! Shows how much I know :)
>
> I don't fully agree with Eric that changing the defaults should be treated
> as an API break -- yes, it may irritate a minority of users, but their code
> will still run. I'd flip around your argument for the role of rcParams and
> customization: the majority user is probably someone who doesn't know much
> about rcParams, or all the ways plots can be customized. *That* is the use
> case to optimize, not the "legacy" users invested in the current style.
>

I whole-heartedly agree.



>
> However, default tweaking need not be painful. As has been mentioned, a
> first step would be an easier way to change a whole set of rcParams:
> something like mpl.set_style('style-name'). As long as one style is
> 'classic', users can keep the current style for as long as they want. It's
> a one line fix, and could even be rcParams-settable.
>

This is already implemented! The problem is, it's hidden away in the
mpltools toolkit:

http://tonysyu.github.io/mpltools/

which nobody seems to know about or use, which is a great shame, since it's
first class -- great job, Tony!

The first example there is:

>>> from mpltools import style>>> style.use('ggplot')

and then the plot is suddenly jaw-droppingly beautiful!

This is achieved with style files which just have lists of matplotlib
params like this:

patch.linewidth = 0.5
patch.facecolor = '#348ABD'  # blue
patch.edgecolor = '#EE'
patch.antialiased = True

These are parsed using the ConfigObj package (this package parses config
files of this type).

Somebody (Chris?) tweeted something about the Vega package earlier:
http://trifacta.github.io/vega/

They seem to have these kind of things solved already (disclaimer: I only
browsed briefly their site) using JSON, but actually Tony's approach seems
like a winner.

mpltools may be installed with

> pip install ConfigObj
> pip install mpltools

[For some reason the dependency on ConfigObj is not registered in mpltools.
Tony, are you the packager?]

This is all *crying out* to be dropped straight into matplotlib proper!

David






>
> With such a framework, it would be possible for people to contribute new
> styles that ship with MPL, and users could change styles without having to
> find (and potentially merge) rcParams files from the web. Finally, people
> could nominate that mature styles be made default (you could even assign
> version numbers to track the default style as it evolves towards visual
> awesomeness)
>
> chris
>
>
>
> On Sat, Jul 20, 2013 at 9:07 PM, Eric Firing  wrote:
>
>> On 2013/07/20 2:38 PM, David P. Sanders wrote:
>> > And this is my problem with 'rc':  it brings to mind an arcane config
>> > file hidden away somewhere that has a terrible syntax and must not be
>> > touched.
>> >
>> > As Chris and Adrian have emphasized, the point is that we *should* be
>> > tweaking away at the parameters all the time.
>> > I propose to rename as  mpl_params=rcParams
>> >
>>
>> Yes, mpl_params is more descriptive and easy to remember.  rcParams is
>> ugly, obscure, and archaic.  It will have to remain available for a long
>> time, but I don't object to changing standard usage to a nicer name.
>> There might even be a better name than "mpl_params"--"settings" comes to
>> mind, or maybe "style".
>>
>> As for parameter tweaking: the defaults shipped with mpl should be
>> changed only rarely, but we should make it as easy as possible for users
>> to customize plots, including coming up with good combinations of style
>> parameters.  In some cases it makes sense to do this via a matplotlibrc
>> file, in other cases it is better to do the parameter setting explicitly
>> at the top of a script.
>>
>> Regarding defaults, note that I said "rarely", not "never".
>>
>> The whole rc system could use a good review--maybe resulting in lots of
>> changes, maybe not--so I welcome the attention you are directing to it.
>>
>> Eric
>>
>>
>> --
>> See everything from the browser to the database with AppDynamics
>> Get end-to-end visibility with application monitoring from AppDynamics
>> Isolate bottlenecks and diagnose root cause in seconds.
>> Start your free trial of AppDynamics Pro today!
>>
>> http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk
>> ___
>> Matplotlib-devel mailing list
>> Matplotlib-devel@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/matplotlib-devel
>>
>
>
>
> --
> 
> Chris Beaumont
> Graduate Student
> Institute for Astronomy
> University of Hawaii at Manoa
> 2680 Woodlawn Drive
> Honolulu, HI 96822
> www.ifa.hawaii.edu/~beaumont
> 
>
>
> --
> See everything from the browser to the database with Ap

[matplotlib-devel] rcParams -> settings

2013-07-20 Thread David P. Sanders
Just saw Eric's post (but the mailing list has yet to update to send me the
individual posts apparently, hence the new title of this email).

+1 (or +100) for using 'settings' !

Here is the new version of my notebook:

http://nbviewer.ipython.org/urls/raw.github.com/dpsanders/IPython-notebooks/master/matplotlib_settings.ipynb

*Boy*, does the IPython Notebook desperately need find and replace!!

David
--
See everything from the browser to the database with AppDynamics
Get end-to-end visibility with application monitoring from AppDynamics
Isolate bottlenecks and diagnose root cause in seconds.
Start your free trial of AppDynamics Pro today!
http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk___
Matplotlib-devel mailing list
Matplotlib-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel


[matplotlib-devel] Wiki page for style ideas

2013-07-20 Thread David P. Sanders
I have created a page on the Wiki for listing ideas to do with styling:

https://github.com/matplotlib/matplotlib/wiki/Matplotlib-style-suggestions

David

-- 
Dr. David P. Sanders

Profesor Titular "A" / Associate Professor
Departamento de Física, Facultad de Ciencias
Universidad Nacional Autónoma de México (UNAM)

dpsand...@ciencias.unam.mx
http://sistemas.fciencias.unam.mx/~dsanders

Cubículo / office: #414, 4o. piso del Depto. de Física

Tel.: +52 55 5622 4965
--
See everything from the browser to the database with AppDynamics
Get end-to-end visibility with application monitoring from AppDynamics
Isolate bottlenecks and diagnose root cause in seconds.
Start your free trial of AppDynamics Pro today!
http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk___
Matplotlib-devel mailing list
Matplotlib-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel


Re: [matplotlib-devel] Plot or Not: voting to create better matplotlibrc

2013-07-20 Thread Kevin Davies

  
  
Regarding whole sets of rcParams, you may want to look at this: 

https://github.com/tonysyu/mpltools

Kevin

On 07/20/2013 09:48 PM, Chris Beaumont
  wrote:


  'image.cmap' -- nice! Shows how much I know :)


I don't fully agree with Eric that changing the defaults
  should be treated as an API break -- yes, it may irritate a
  minority of users, but their code will still run. I'd flip
  around your argument for the role of rcParams and
  customization: the majority user is probably someone who
  doesn't know much about rcParams, or all the ways plots can be
  customized. *That* is the use case to optimize, not the
  "legacy" users invested in the current style.


However, default tweaking need not be painful. As has been
  mentioned, a first step would be an easier way to change a
  whole set of rcParams: something like
  mpl.set_style('style-name'). As long as one style is
  'classic', users can keep the current style for as long as
  they want. It's a one line fix, and could even be
  rcParams-settable.


With such a framework, it would be possible for people to
  contribute new styles that ship with MPL, and users could
  change styles without having to find (and potentially merge)
  rcParams files from the web. Finally, people could nominate
  that mature styles be made default (you could even assign
  version numbers to track the default style as it evolves
  towards visual awesomeness)


chris
 
  
  

On Sat, Jul 20, 2013 at 9:07 PM, Eric
  Firing 
  wrote:
  
On 2013/07/20 2:38 PM, David P. Sanders
  wrote:
  > And this is my problem with 'rc':  it brings to mind
  an arcane config
  > file hidden away somewhere that has a terrible syntax
  and must not be
  > touched.
  >
  > As Chris and Adrian have emphasized, the point is
  that we *should* be
  > tweaking away at the parameters all the time.
  > I propose to rename as  mpl_params=rcParams
  >
  

Yes, mpl_params is more descriptive and easy to remember.
 rcParams is
ugly, obscure, and archaic.  It will have to remain
available for a long
time, but I don't object to changing standard usage to a
nicer name.
There might even be a better name than
"mpl_params"--"settings" comes to
mind, or maybe "style".

As for parameter tweaking: the defaults shipped with mpl
should be
changed only rarely, but we should make it as easy as
possible for users
to customize plots, including coming up with good
combinations of style
parameters.  In some cases it makes sense to do this via a
matplotlibrc
file, in other cases it is better to do the parameter
setting explicitly
at the top of a script.

Regarding defaults, note that I said "rarely", not "never".

The whole rc system could use a good review--maybe resulting
in lots of
changes, maybe not--so I welcome the attention you are
directing to it.

Eric
  

  
--
See everything from the browser to the database with
AppDynamics
Get end-to-end visibility with application monitoring
from AppDynamics
Isolate bottlenecks and diagnose root cause in seconds.
Start your free trial of AppDynamics Pro today!
http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk
___
Matplotlib-devel mailing list
Matplotlib-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel
  

  





-- 

Chris Beaumont
Graduate Student
Institute for Astronomy
University of Hawaii at Manoa
2680 Woodlawn Drive
Honolulu, HI 96822
www.ifa.hawaii.edu/~beaumont

  
  
  
  
  --