i was wondering if anyone had considered making a matplotlibrc which generates plots suitable for ieee publications (specifically ieee transactions)? or any other publications for that matter. like a set of matching matplotlibrc's to journals (or some other way to achieve a similar functionality) if not, i think it would be a valuable thing to make, because it wouldnt be very hard, and would save a lot of users time/effort. specifically it would specify the dimension/dpi/font type/sizes/etc. i have a preliminary one for ieee we can use as a starting point, that can be improved. thanks alex
Good Idea ! I'm also using mpl for other publications than ieee and it sounds like a small mplrc data base with targeted journal specifications would be worthwhile doing ! I would be ready to contribute. Cheers, Auré ________________________________ De : alex arsenovic <ai...@vi...> À : mat...@li... Envoyé le : Ven 15 avril 2011, 14h 06min 39s Objet : [Matplotlib-users] matplotlibrc for [ieee] publications i was wondering if anyone had considered making a matplotlibrc which generates plots suitable for ieee publications (specifically ieee transactions)? or any other publications for that matter. like a set of matching matplotlibrc's to journals (or some other way to achieve a similar functionality) if not, i think it would be a valuable thing to make, because it wouldnt be very hard, and would save a lot of users time/effort. specifically it would specify the dimension/dpi/font type/sizes/etc. i have a preliminary one for ieee we can use as a starting point, that can be improved. thanks alex ------------------------------------------------------------------------------ Benefiting from Server Virtualization: Beyond Initial Workload Consolidation -- Increasing the use of server virtualization is a top priority.Virtualization can reduce costs, simplify management, and improve application availability and disaster protection. Learn more about boosting the value of server virtualization. http://p.sf.net/sfu/vmware-sfdev2dev _______________________________________________ Matplotlib-users mailing list Mat...@li... https://lists.sourceforge.net/lists/listinfo/matplotlib-users
I have previously used some script from Mike DePalatis for making APS (PRL, PRB, etc.) suitable plots. Maybe it will be a useful starting point. http://mike.depalatis.net/docs/mpllatex.html """ mplparams.py M.V. DePalatis, 2010年09月01日 Licensed under the GNU GPL v3 matplotlib rc params and axes rects to generate figures of appropriate size for different types of publication. """ # documentclass 'article' with package 'fullpage' fullpage = {'params': {'axes.labelsize': 10, 'text.fontsize': 10, 'legend.fontsize': 10, 'xtick.labelsize': 8, 'ytick.labelsize': 8, 'text.usetex': False, 'font.family': 'serif', 'figure.figsize': (4.774, 2.950)}, 'axes': [0.150,0.175,0.95-0.15,0.95-0.25]} # two-column APS journal format aps = {'params': {'axes.labelsize': 10, 'text.fontsize': 10, 'legend.fontsize': 10, 'xtick.labelsize': 8, 'ytick.labelsize': 8, 'text.usetex': False, 'figure.figsize': (3.4039, 2.1037)}, 'axes': [0.125,0.2,0.95-0.125,0.95-0.2]} On 15/04/2011 14:36, Auré Gourrier wrote: > Good Idea ! > I'm also using mpl for other publications than ieee and it sounds like > a small mplrc data base with targeted journal specifications would be > worthwhile doing ! I would be ready to contribute. > Cheers, > Auré > > ------------------------------------------------------------------------ > *De :* alex arsenovic <ai...@vi...> > *À :* mat...@li... > *Envoyé le :* Ven 15 avril 2011, 14h 06min 39s > *Objet :* [Matplotlib-users] matplotlibrc for [ieee] publications > > i was wondering if anyone had considered making a matplotlibrc which > generates plots suitable for ieee publications (specifically ieee > transactions)? > > or any other publications for that matter. like a set of matching > matplotlibrc's to journals (or some other way to achieve a similar > functionality) > > if not, i think it would be a valuable thing to make, because it wouldnt > be very hard, and would save a lot of users time/effort. specifically it > would specify the dimension/dpi/font type/sizes/etc. i have a > preliminary one for ieee we can use as a starting point, that can be > improved. > > > thanks > alex > > > > ------------------------------------------------------------------------------ > Benefiting from Server Virtualization: Beyond Initial Workload > Consolidation -- Increasing the use of server virtualization is a top > priority.Virtualization can reduce costs, simplify management, and > improve > application availability and disaster protection. Learn more about > boosting > the value of server virtualization. http://p.sf.net/sfu/vmware-sfdev2dev > _______________________________________________ > Matplotlib-users mailing list > Mat...@li... > <mailto:Mat...@li...> > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > > > ------------------------------------------------------------------------------ > Benefiting from Server Virtualization: Beyond Initial Workload > Consolidation -- Increasing the use of server virtualization is a top > priority.Virtualization can reduce costs, simplify management, and improve > application availability and disaster protection. Learn more about boosting > the value of server virtualization. http://p.sf.net/sfu/vmware-sfdev2dev > > > _______________________________________________ > Matplotlib-users mailing list > Mat...@li... > https://lists.sourceforge.net/lists/listinfo/matplotlib-users
this seems like the right way to do it. maybe it can be included in the matplotlib package? alex On Fri, 2011年04月15日 at 15:54 +0200, Adrian Hill wrote: > I have previously used some script from Mike DePalatis for making APS > (PRL, PRB, etc.) suitable plots. Maybe it will be a useful starting > point. > > http://mike.depalatis.net/docs/mpllatex.html > > > """ > mplparams.py > > M.V. DePalatis, 2010年09月01日 > Licensed under the GNU GPL v3 > > matplotlib rc params and axes rects to generate figures of appropriate > size for different types of publication. > """ > > # documentclass 'article' with package 'fullpage' > fullpage = {'params': {'axes.labelsize': 10, > 'text.fontsize': 10, > 'legend.fontsize': 10, > 'xtick.labelsize': 8, > 'ytick.labelsize': 8, > 'text.usetex': False, > 'font.family': 'serif', > 'figure.figsize': (4.774, 2.950)}, > 'axes': [0.150,0.175,0.95-0.15,0.95-0.25]} > > # two-column APS journal format > aps = {'params': {'axes.labelsize': 10, > 'text.fontsize': 10, > 'legend.fontsize': 10, > 'xtick.labelsize': 8, > 'ytick.labelsize': 8, > 'text.usetex': False, > 'figure.figsize': (3.4039, 2.1037)}, > 'axes': [0.125,0.2,0.95-0.125,0.95-0.2]} > > > > On 15/04/2011 14:36, Auré Gourrier wrote: > > Good Idea ! > > I'm also using mpl for other publications than ieee and it sounds > > like a small mplrc data base with targeted journal specifications > > would be worthwhile doing ! I would be ready to contribute. > > Cheers, > > Auré > > > > > > > > ____________________________________________________________________ > > De : alex arsenovic <ai...@vi...> > > À : mat...@li... > > Envoyé le : Ven 15 avril 2011, 14h 06min 39s > > Objet : [Matplotlib-users] matplotlibrc for [ieee] publications > > > > i was wondering if anyone had considered making a matplotlibrc which > > generates plots suitable for ieee publications (specifically ieee > > transactions)? > > > > or any other publications for that matter. like a set of matching > > matplotlibrc's to journals (or some other way to achieve a similar > > functionality) > > > > if not, i think it would be a valuable thing to make, because it > > wouldnt > > be very hard, and would save a lot of users time/effort. > > specifically it > > would specify the dimension/dpi/font type/sizes/etc. i have a > > preliminary one for ieee we can use as a starting point, that can be > > improved. > > > > > > thanks > > alex > > > > > > > > ------------------------------------------------------------------------------ > > Benefiting from Server Virtualization: Beyond Initial Workload > > Consolidation -- Increasing the use of server virtualization is a > > top > > priority.Virtualization can reduce costs, simplify management, and > > improve > > application availability and disaster protection. Learn more about > > boosting > > the value of server virtualization. > > http://p.sf.net/sfu/vmware-sfdev2dev > > _______________________________________________ > > Matplotlib-users mailing list > > Mat...@li... > > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > > > > > > ------------------------------------------------------------------------------ > > Benefiting from Server Virtualization: Beyond Initial Workload > > Consolidation -- Increasing the use of server virtualization is a top > > priority.Virtualization can reduce costs, simplify management, and improve > > application availability and disaster protection. Learn more about boosting > > the value of server virtualization. http://p.sf.net/sfu/vmware-sfdev2dev > > > > _______________________________________________ > > Matplotlib-users mailing list > > Mat...@li... > > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > > ------------------------------------------------------------------------------ > Benefiting from Server Virtualization: Beyond Initial Workload > Consolidation -- Increasing the use of server virtualization is a top > priority.Virtualization can reduce costs, simplify management, and improve > application availability and disaster protection. Learn more about boosting > the value of server virtualization. http://p.sf.net/sfu/vmware-sfdev2dev > _______________________________________________ Matplotlib-users mailing list Mat...@li... https://lists.sourceforge.net/lists/listinfo/matplotlib-users
It would be great to include this in matplotlib. However, I think it's not unreasonable to expect that these things would evolve faster than the release cycle of matplotlib. Perhaps a user is stuck on an older version of matplotlib because they want to use pre-built packages etc., or whatever reason. It might be better to provide this in a form that is easily updatable without updating the rest of matplotlib. Of course, small problems may arise if they use rcParams available not available in the user's version of matplotlib. (For the most part, I think the risk of that is quite small, as the rcParams that are most useful here have been stable for a long time.) We could use the existing "cbook.get_sample_data", which grabs files from the matplotlib git repo, for this. It would also be nice to generate a gallery of these settings and make it available online, linked from the documentation (again, maybe not *part* of the documentation, because it should update more frequently). Cheers, Mike On 04/15/2011 10:48 AM, alex arsenovic wrote: > this seems like the right way to do it. maybe it can be included in the > matplotlib package? > > alex > > > On Fri, 2011年04月15日 at 15:54 +0200, Adrian Hill wrote: > >> I have previously used some script from Mike DePalatis for making APS >> (PRL, PRB, etc.) suitable plots. Maybe it will be a useful starting >> point. >> >> http://mike.depalatis.net/docs/mpllatex.html >> >> >> """ >> mplparams.py >> >> M.V. DePalatis, 2010年09月01日 >> Licensed under the GNU GPL v3 >> >> matplotlib rc params and axes rects to generate figures of appropriate >> size for different types of publication. >> """ >> >> # documentclass 'article' with package 'fullpage' >> fullpage = {'params': {'axes.labelsize': 10, >> 'text.fontsize': 10, >> 'legend.fontsize': 10, >> 'xtick.labelsize': 8, >> 'ytick.labelsize': 8, >> 'text.usetex': False, >> 'font.family': 'serif', >> 'figure.figsize': (4.774, 2.950)}, >> 'axes': [0.150,0.175,0.95-0.15,0.95-0.25]} >> >> # two-column APS journal format >> aps = {'params': {'axes.labelsize': 10, >> 'text.fontsize': 10, >> 'legend.fontsize': 10, >> 'xtick.labelsize': 8, >> 'ytick.labelsize': 8, >> 'text.usetex': False, >> 'figure.figsize': (3.4039, 2.1037)}, >> 'axes': [0.125,0.2,0.95-0.125,0.95-0.2]} >> >> >> >> On 15/04/2011 14:36, Auré Gourrier wrote: >> >>> Good Idea ! >>> I'm also using mpl for other publications than ieee and it sounds >>> like a small mplrc data base with targeted journal specifications >>> would be worthwhile doing ! I would be ready to contribute. >>> Cheers, >>> Auré >>> >>> >>> >>> ____________________________________________________________________ >>> De : alex arsenovic<ai...@vi...> >>> À : mat...@li... >>> Envoyé le : Ven 15 avril 2011, 14h 06min 39s >>> Objet : [Matplotlib-users] matplotlibrc for [ieee] publications >>> >>> i was wondering if anyone had considered making a matplotlibrc which >>> generates plots suitable for ieee publications (specifically ieee >>> transactions)? >>> >>> or any other publications for that matter. like a set of matching >>> matplotlibrc's to journals (or some other way to achieve a similar >>> functionality) >>> >>> if not, i think it would be a valuable thing to make, because it >>> wouldnt >>> be very hard, and would save a lot of users time/effort. >>> specifically it >>> would specify the dimension/dpi/font type/sizes/etc. i have a >>> preliminary one for ieee we can use as a starting point, that can be >>> improved. >>> >>> >>> thanks >>> alex >>> >>> >>> >>> ------------------------------------------------------------------------------ >>> Benefiting from Server Virtualization: Beyond Initial Workload >>> Consolidation -- Increasing the use of server virtualization is a >>> top >>> priority.Virtualization can reduce costs, simplify management, and >>> improve >>> application availability and disaster protection. Learn more about >>> boosting >>> the value of server virtualization. >>> http://p.sf.net/sfu/vmware-sfdev2dev >>> _______________________________________________ >>> Matplotlib-users mailing list >>> Mat...@li... >>> https://lists.sourceforge.net/lists/listinfo/matplotlib-users >>> >>> >>> ------------------------------------------------------------------------------ >>> Benefiting from Server Virtualization: Beyond Initial Workload >>> Consolidation -- Increasing the use of server virtualization is a top >>> priority.Virtualization can reduce costs, simplify management, and improve >>> application availability and disaster protection. Learn more about boosting >>> the value of server virtualization. http://p.sf.net/sfu/vmware-sfdev2dev >>> >>> _______________________________________________ >>> Matplotlib-users mailing list >>> Mat...@li... >>> https://lists.sourceforge.net/lists/listinfo/matplotlib-users >>> >> ------------------------------------------------------------------------------ >> Benefiting from Server Virtualization: Beyond Initial Workload >> Consolidation -- Increasing the use of server virtualization is a top >> priority.Virtualization can reduce costs, simplify management, and improve >> application availability and disaster protection. Learn more about boosting >> the value of server virtualization. http://p.sf.net/sfu/vmware-sfdev2dev >> _______________________________________________ Matplotlib-users mailing list Mat...@li... https://lists.sourceforge.net/lists/listinfo/matplotlib-users >> > > > ------------------------------------------------------------------------------ > Benefiting from Server Virtualization: Beyond Initial Workload > Consolidation -- Increasing the use of server virtualization is a top > priority.Virtualization can reduce costs, simplify management, and improve > application availability and disaster protection. Learn more about boosting > the value of server virtualization. http://p.sf.net/sfu/vmware-sfdev2dev > _______________________________________________ > Matplotlib-users mailing list > Mat...@li... > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > -- Michael Droettboom Science Software Branch Space Telescope Science Institute Baltimore, Maryland, USA
On Fri, Apr 15, 2011 at 8:36 AM, Auré Gourrier <aur...@ya...>wrote: > Good Idea ! > I'm also using mpl for other publications than ieee and it sounds like a > small mplrc data base with targeted journal specifications would be > worthwhile doing ! I would be ready to contribute. > Cheers, > Auré > > Is there any reason this needs to done with rc files? I prefer to put document-specific configuration into modules. For example, you could have a module that looks like: mplrc/ __init__.py aps_fullpage.py aps_twocolumn.py ieee.py ... (`aps` could even be directory). And each module would set rc parameters using function calls; for example, aps_twocolumn.py might look like: import matplotlib.pyplot as plt plt.rc('axes', labelsize=10) plt.rc('text', fontsize=10) plt.rc('legend', fontsize=10) plt.rc('xtick', labelsize=8) plt.rc('ytick', labelsize=8) plt.rc('text', usetex=False) plt.rc('figure', figsize=(3.4039, 2.1037)) (Alternatively, you could create a separate rc file and just have the module load that rc file). The advantage of this module-based approach is that you could simply import the module whenever you need it (e.g., just add `import mplrc.aps_twocolumn` at the top of your script). If I used an rc file instead, I'd have to copy the rc file to my working directory each time, or somehow, manually load the rc file from a path. Just a suggestion. -Tony
i like the module-based idea. its a bit overkill for the functionality needed, but the concise call makes it very convenient. also, installation and updating would be easy through pip/easy_install. should i start a google-code project? or does someone have a preferred way to start this? alex On Fri, 2011年04月15日 at 14:09 -0400, Tony Yu wrote: > > > On Fri, Apr 15, 2011 at 8:36 AM, Auré Gourrier > <aur...@ya...> wrote: > Good Idea ! > I'm also using mpl for other publications than ieee and it > sounds like a small mplrc data base with targeted journal > specifications would be worthwhile doing ! I would be ready to > contribute. > Cheers, > Auré > > > > > Is there any reason this needs to done with rc files? I prefer to put > document-specific configuration into modules. For example, you could > have a module that looks like: > > mplrc/ > __init__.py > aps_fullpage.py > aps_twocolumn.py > ieee.py > ... > > (`aps` could even be directory). And each module would set rc > parameters using function calls; for example, aps_twocolumn.py might > look like: > > import matplotlib.pyplot as plt > plt.rc('axes', labelsize=10) > plt.rc('text', fontsize=10) > plt.rc('legend', fontsize=10) > plt.rc('xtick', labelsize=8) > plt.rc('ytick', labelsize=8) > plt.rc('text', usetex=False) > plt.rc('figure', figsize=(3.4039, 2.1037)) > > (Alternatively, you could create a separate rc file and just have the > module load that rc file). The advantage of this module-based approach > is that you could simply import the module whenever you need it (e.g., > just add `import mplrc.aps_twocolumn` at the top of your script). If I > used an rc file instead, I'd have to copy the rc file to my working > directory each time, or somehow, manually load the rc file from a > path. > > Just a suggestion. > > -Tony >
i created the project for 'mplrc' here https://code.google.com/p/mplrc/ let me know what you all think. if you all send me your publications' settings i can add them, or if you want an account ill make you one. one thing to mention is that the params dictionary probably should set all possible settings so that there is no ambiguity. i have yet to do this. here is an example of my ieee format On Fri, 2011年04月15日 at 14:09 -0400, Tony Yu wrote: > > > On Fri, Apr 15, 2011 at 8:36 AM, Auré Gourrier > <aur...@ya...> wrote: > Good Idea ! > I'm also using mpl for other publications than ieee and it > sounds like a small mplrc data base with targeted journal > specifications would be worthwhile doing ! I would be ready to > contribute. > Cheers, > Auré > > > > > Is there any reason this needs to done with rc files? I prefer to put > document-specific configuration into modules. For example, you could > have a module that looks like: > > mplrc/ > __init__.py > aps_fullpage.py > aps_twocolumn.py > ieee.py > ... > > (`aps` could even be directory). And each module would set rc > parameters using function calls; for example, aps_twocolumn.py might > look like: > > import matplotlib.pyplot as plt > plt.rc('axes', labelsize=10) > plt.rc('text', fontsize=10) > plt.rc('legend', fontsize=10) > plt.rc('xtick', labelsize=8) > plt.rc('ytick', labelsize=8) > plt.rc('text', usetex=False) > plt.rc('figure', figsize=(3.4039, 2.1037)) > > (Alternatively, you could create a separate rc file and just have the > module load that rc file). The advantage of this module-based approach > is that you could simply import the module whenever you need it (e.g., > just add `import mplrc.aps_twocolumn` at the top of your script). If I > used an rc file instead, I'd have to copy the rc file to my working > directory each time, or somehow, manually load the rc file from a > path. > > Just a suggestion. > > -Tony >
hi, just curious if anyone wants to add some publication formating settings? if you send me the rc params, and publication infos i add them to the project. http://code.google.com/p/mplrc/ On Sat, 2011年04月16日 at 14:21 -0400, alex arsenovic wrote: > i created the project for 'mplrc' here > https://code.google.com/p/mplrc/ > > let me know what you all think. if you all send me your publications' > settings i can add them, or if you want an account ill make you one. > > one thing to mention is that the params dictionary probably should set > all possible settings so that there is no ambiguity. i have yet to do > this. > > here is an example of my ieee format > > > On Fri, 2011年04月15日 at 14:09 -0400, Tony Yu wrote: > > > > > > On Fri, Apr 15, 2011 at 8:36 AM, Auré Gourrier > > <aur...@ya...> wrote: > > Good Idea ! > > I'm also using mpl for other publications than ieee and it > > sounds like a small mplrc data base with targeted journal > > specifications would be worthwhile doing ! I would be ready to > > contribute. > > Cheers, > > Auré > > > > > > > > > > Is there any reason this needs to done with rc files? I prefer to put > > document-specific configuration into modules. For example, you could > > have a module that looks like: > > > > mplrc/ > > __init__.py > > aps_fullpage.py > > aps_twocolumn.py > > ieee.py > > ... > > > > (`aps` could even be directory). And each module would set rc > > parameters using function calls; for example, aps_twocolumn.py might > > look like: > > > > import matplotlib.pyplot as plt > > plt.rc('axes', labelsize=10) > > plt.rc('text', fontsize=10) > > plt.rc('legend', fontsize=10) > > plt.rc('xtick', labelsize=8) > > plt.rc('ytick', labelsize=8) > > plt.rc('text', usetex=False) > > plt.rc('figure', figsize=(3.4039, 2.1037)) > > > > (Alternatively, you could create a separate rc file and just have the > > module load that rc file). The advantage of this module-based approach > > is that you could simply import the module whenever you need it (e.g., > > just add `import mplrc.aps_twocolumn` at the top of your script). If I > > used an rc file instead, I'd have to copy the rc file to my working > > directory each time, or somehow, manually load the rc file from a > > path. > > > > Just a suggestion. > > > > -Tony > > >