Re: [Matplotlib-users] [matplotlib-devel] License, freetype

2017-02-18 Thread Paul Hobson
thing like Anaconda, which I'd > rather not do because I have Python already installed. > > If you have any other ideas, I'd be happy to hear them. > > Best, > Chad > > > -- > *From:* Joe Kington <joferking...@gmail.com> > *To:* Paul Ho

Re: [Matplotlib-users] License, freetype

2017-02-17 Thread Paul Hobson
Chad, My recollections is that matplotlib doesn't distribute the source code to FreeType, it only uses it as a dependency. As such, MPL is in the clear with its more permissive licensing. -Paul On Fri, Feb 17, 2017 at 12:45 PM, CAB wrote: > Hi, All, > > I just went to

Re: [Matplotlib-users] subplot layout

2016-04-26 Thread Paul Hobson
(Mobile) > E-mail:sjo.in...@gmail.com;sudheer.jos...@yahoo.com Web- > http://oppamthadathil.tripod.com > ******* > > > On Mon, 25/4/16, Paul Hobson <pmhob...@gmail.com> wrote: > > Subject: Re: [Matplotlib-users] subplot layout > To: "Sudheer Joseph"

Re: [Matplotlib-users] subplot layout

2016-04-25 Thread Paul Hobson
Your basemap plot is likely setting the aspect of the axes to "equal", so it resizes the plot accordingly. Otherwise you'd have a pretty nasty amount of vertical distortion. When you save the figure, using bbox_inches='tight' will trim the excess white space from the margins:

Re: [Matplotlib-users] register colormap collection

2015-10-01 Thread Paul Hobson
On Thu, Oct 1, 2015 at 9:40 AM, Thomas Caswell wrote: > Have a look at how cmocean (https://github.com/matplotlib/cmocean) works > under the hood. > > I think the options are: >- use a module to supply your color maps (from my_cmap_collection > import my_cmap) and then

Re: [Matplotlib-users] boxplot behaviour in an extreme scenario

2015-08-26 Thread Paul Hobson
Are you running python 2 or python 3? If you're on python 2, what happens if you add from __future__ import division to the top of your script? On Tue, Aug 25, 2015 at 10:31 PM, chtan ch...@unisim.edu.sg wrote: Hi, the outliers in the boxplot do not seem to be drawn in the following extreme

Re: [Matplotlib-users] boxplot behaviour in an extreme scenario

2015-08-26 Thread Paul Hobson
be happening, though. On Wed, Aug 26, 2015 at 1:08 AM, Paul Hobson pmhob...@gmail.com wrote: Are you running python 2 or python 3? If you're on python 2, what happens if you add from __future__ import division to the top of your script? On Tue, Aug 25, 2015 at 10:31 PM, chtan ch

Re: [Matplotlib-users] boxplot behaviour in an extreme scenario

2015-08-26 Thread Paul Hobson
Even though I'm familiar with the boxplot source code, I largely use IPython for quick investigations like this. In IPython, doing something like matplotlib.Axes.boxplot?? shows the full source code for that functions\. Then I saw/remembered that boxplot now just calls

Re: [Matplotlib-users] @image_comparison decorator and unittests

2015-07-30 Thread Paul Hobson
, Jens Nielsen jenshniel...@gmail.com wrote: Thomas Robitailles pytest image comparison plugin might also be of interest https://github.com/astrofrog/pytest-mpl Jens tor. 30. jul. 2015 kl. 14.43 skrev Thomas Caswell tcasw...@gmail.com: Paul Hobson expressed interest in making it easier

Re: [Matplotlib-users] Misleading BoundaryNorm error

2015-07-29 Thread Paul Hobson
On Wed, Jul 29, 2015 at 3:18 AM, Fabien fabien.mauss...@gmail.com wrote: Folks, still in my exploring phase of Matplotlib's ecosystem I ran into following mismatch between the APIs of BoundaryNorm and Normalize. See the following example: import matplotlib as mpl c = mpl.cm.get_cmap()

Re: [Matplotlib-users] Produce KML from Matplolib

2015-06-21 Thread Paul Hobson
Eric, You'll be producing the KML from pythonor some other python package. GIS I/O is well beyond matplotlib's scope. This gis,stackexchange thread seems promising: http://gis.stackexchange.com/questions/22519/create-a-ground-overlay-kml-from-georeferenced-raster On Wed, Jun 10, 2015 at 1:07

Re: [Matplotlib-users] custom x axis integers boxplot

2015-06-16 Thread Paul Hobson
You want to use a MultipleLocator: http://matplotlib.org/examples/pylab_examples/major_minor_demo1.html -paul On Mon, Jun 15, 2015 at 6:16 PM, pb89 peterbehrin...@gmx.de wrote: hey guys, is it also possible to only show every 5th number of that array? Its a little too much right now:

Re: [Matplotlib-users] custom x axis integers boxplot

2015-06-13 Thread Paul Hobson
Oh sorry that should be ... positions=np.arange(11, 36)) On Sat, Jun 13, 2015 at 7:49 AM, pb89 peterbehrin...@gmx.de wrote: it tried this before, but it throws an exception: TypeError: boxplot() got an unexpected keyword argument 'pos' -- View this message in context:

Re: [Matplotlib-users] custom x axis integers boxplot

2015-06-13 Thread Paul Hobson
Probably a better way would be to the the pos arguments to boxplot (bp=boxplot(array, pos=range(11, 36)). That *should* work. Let me know if it doesn't. On Fri, Jun 12, 2015 at 4:36 PM, pb89 peterbehrin...@gmx.de wrote: thanks for the quick answer Jeffrey, its working! -peter -- View

Re: [Matplotlib-users] Basemap Problems

2015-06-08 Thread Paul Hobson
Edgar, You feed lat/lon (float) values. See this example here: http://matplotlib.org/basemap/users/cea.html And a whole collection of setting up maps in other projection here: http://matplotlib.org/basemap/users/mapsetup.html You also need to make sure that all of inputs make sense together

Re: [Matplotlib-users] for Posterior predictive data distributions

2015-06-07 Thread Paul Hobson
(apologies if the list receives this twice) On Fri, Jun 5, 2015 at 9:14 AM, Juan Wu wujua...@gmail.com wrote: Hi, Experts, My colleagues and I have a question, how we can make a plot via python like below. According to a guy's original paper, Each panel shows the normalized histograms of

Re: [Matplotlib-users] [matplotlib-devel] RFC: candidates for a new default colormap

2015-06-05 Thread Paul Hobson
On Fri, Jun 5, 2015 at 9:17 AM, Jody Klymak jkly...@uvic.ca wrote: Anyways, I guess I am advocating trying to find a colormap with a very obvious central hue to represent zero. Anomaly data sets are *very* common, so having a default colormap that doesn’t do something reasonable with them

Re: [Matplotlib-users] plot() and imshow() relationship

2015-05-29 Thread Paul Hobson
imshow is for displaying arrays as images/rasters. plot is for showing data/functions as points and lines. See the gallery for imshow: http://matplotlib.org/gallery.html#images_contours_and_fields On Fri, May 29, 2015 at 4:12 AM, Amit Saha amitsaha...@gmail.com wrote: Hi all, I am trying

Re: [Matplotlib-users] [matplotlib-devel] Easy problem working with dev library

2015-05-16 Thread Paul Hobson
anyway you want.  ​-Paul.  On Sat, May 16, 2015 at 5:52 PM, Paul Hobson pmhob...@gmail.com wrote: After you've setup your development environment with all of the MPL dependencies, navigate to the MPL source directory and install it with: $ python setup.py develop or $ pip

Re: [Matplotlib-users] GridSpec.GridSpecFromSubplotSpec.update()

2015-04-03 Thread Paul Hobson
Hey Julian, I'm not familiar enough from gridspec to help, but your emails were received by the list. If no one on the list has (time to write) a response, I would recommend making your example a little more reproducible (e.g., what are a and b?) and posting it on stackoverflow. On Fri, Apr 3,

Re: [Matplotlib-users] Interactive Applications using Matplotlib

2015-03-31 Thread Paul Hobson
Congrats, Ben. I know you've been working hard on this for a long time and I'm sure it'll be a great value to those looking to use matplotlib beyond just making a quick figure for a report.  -Paul  — Sent from Mailbox On Tue, Mar 31, 2015 at 11:02 AM, Benjamin Root ben.v.r...@gmail.com

Re: [Matplotlib-users] segmentation fault when saving images

2015-03-19 Thread Paul Hobson
What happens when you edit your program to avoid dividing by zero? -p — Sent from Mailbox On Thu, Mar 19, 2015 at 10:14 AM, Gabriele Brambilla gb.gabrielebrambi...@gmail.com wrote: Hi guys, I don't understand why now, after I save an image when it is prompted out, the image is not saved

Re: [Matplotlib-users] Corr plot in subplot

2015-03-17 Thread Paul Hobson
: Subject: Re: [Matplotlib-users] Corr plot in subplot To: Paul Hobson pmhob...@gmail.com, Adam Hughes hughesada...@gmail.com Cc: Matplotlib Users matplotlib-users@lists.sourceforge.net Date: Tuesday, 17 March, 2015, 8:31 AM Hi Paul,                 I could not succeed in plotting

Re: [Matplotlib-users] Problems with pyplot and cm in Matplotlib ver. 1.4.3

2015-02-21 Thread Paul Hobson
Hey Starfighter,  I want to help, but I also don't like unzipping files from strangers. Can you make a simple script that generates some fake with numoy and the handful of matplotib commands you need to make the figure.  -p — Sent from Mailbox On Sat, Feb 21, 2015 at 7:34 PM,

Re: [Matplotlib-users] How to add data points to a contour map.

2015-02-12 Thread Paul Hobson
Definitely. Assuming you don't want to do this in an interactive manner (i.e. pointing and clicking with your mouse: fig, ax = plt.subplots() ax.contour(...) ax.plot(x_dots, y_dots, 'ro', label='Dots') -p On Thu, Feb 12, 2015 at 8:07 AM, Dr Sydney Shall sydney.sh...@meshnet.fr wrote: I am a

Re: [Matplotlib-users] synchronize magnification of subplots?

2015-02-03 Thread Paul Hobson
I only have the notebook to mes around in, but the following works for me: %matplotlib nbagg import matplotlib.pyplot as plt fig, ax = plt.subplots(nrows=2, sharex=True, sharey=True) On Tue Feb 03 2015 at 4:07:26 PM Neal Becker ndbeck...@gmail.com wrote: I have 2 subplots, 2 rows 1 col. They

Re: [Matplotlib-users] using it in a Qt5-Widget

2015-01-28 Thread Paul Hobson
At the top of www.matplotlib.org, there is an examples link. Scroll down a bit, there's a section titled user interface examples http://matplotlib.org/examples/user_interfaces/index.html The QT4 example works on my machine currently, so it's reasonably up to date. -p On Wed, Jan 28, 2015 at

Re: [Matplotlib-users] contour3D in matplotlib

2015-01-20 Thread Paul Hobson
The gallery had a comprehensive set of available three dimensional plots, I think. http://matplotlib.org/gallery.html#mplot3d On Tue, Jan 20, 2015 at 01:19 Nils Wagner nils...@googlemail.com wrote: Hi all, I found

Re: [Matplotlib-users] [matplotlib-devel] Matplotlib style gallery

2015-01-05 Thread Paul Hobson
Tony! This is very cool. Bravo. On Mon, Jan 5, 2015 at 8:42 PM, Tony Yu tsy...@gmail.com wrote: I've been playing around with learning Javascript lately. As part of the process, I created a Flask app to build a gallery for matplotlib style sheets:

Re: [Matplotlib-users] two axes

2014-12-02 Thread Paul Hobson
You didn't label any of the series that you put on the graph, so the legend has no idea what to call anything thing. Like the warning (not error) says, use the label parameter on your calls to plot, e.g., ax1.plot(..., label='Concentration') or whatever. Note though, that you're mixing up

Re: [Matplotlib-users] multiple plots on single axis

2014-11-27 Thread Paul Hobson
Check out the third example in the gallery: Gallery Link: http://matplotlib.org/gallery.html Direct Link: http://matplotlib.org/examples/lines_bars_and_markers/fill_demo_features.html On Thu, Nov 27, 2014 at 6:55 AM, Bala subramanian bala.biophys...@gmail.com wrote: Friends, I want to make

Re: [Matplotlib-users] Can not display 3D plot !

2014-11-13 Thread Paul Hobson
Does a fresh conda environment help? On Wed, Nov 12, 2014 at 5:38 PM, Geoffrey Mégardon geoffrey.megar...@gmail.com wrote: Yes, I may forget to tell, but this code is 100% working, it work on other installations I have. So the problem is not in the code. It is just that on my current

Re: [Matplotlib-users] matplotlib save image as postscript, when xlabel is saved as text and not path

2014-11-03 Thread Paul Hobson
What happens when you save as a postscript file with matplotlib.rcParams[text.usetex] = False? -paul On Mon, Nov 3, 2014 at 7:11 AM, Oren oren...@gmail.com wrote: Anyone know how to solve this thing? Thanks. On 2 November 2014 03:40, oren oren...@gmail.com wrote: How can I save a

Re: [Matplotlib-users] matplotlib save image as postscript, when xlabel is saved as text and not path

2014-11-03 Thread Paul Hobson
21:40, Paul Hobson pmhob...@gmail.com wrote: What happens when you save as a postscript file with matplotlib.rcParams[text.usetex] = False? -paul On Mon, Nov 3, 2014 at 7:11 AM, Oren oren...@gmail.com wrote: Anyone know how to solve this thing? Thanks. On 2 November 2014 03:40, oren oren

Re: [Matplotlib-users] 2 overlaid plots with grid??

2014-10-22 Thread Paul Hobson
I seem to recall that the MaxNLocator and some carefully chosen axes limits suffices for me in the past. On Tue, Oct 21, 2014 at 11:44 AM, Adam Hughes hughesada...@gmail.com wrote: I wrote a program that draws grids manually on mpl plots a while back. If you can't find a solution can you

Re: [Matplotlib-users] python3 and basemap bluemarble()

2014-10-17 Thread Paul Hobson
Tom, I believe the pillow package is the actively maintained fork of PIL. Could be wrong on that though. -p On Fri, Oct 17, 2014 at 4:27 AM, Tommy Carstensen tommy.carsten...@gmail.com wrote: To matplotlib-users, basemap bluemarble() requires PIL, which is not available for Python3. What

Re: [Matplotlib-users] Using unregistered scales

2014-10-07 Thread Paul Hobson
Here's that second link for the scale: https://gist.github.com/phobson/3cc3550ce1efcc299142 On Mon, Oct 6, 2014 at 1:27 PM, Paul Hobson pmhob...@gmail.com wrote: MPL Users, Using [1] as a template, I built a ProbabilityScale[2] which I hope one day will be in the statsmodels library

[Matplotlib-users] Using unregistered scales

2014-10-06 Thread Paul Hobson
MPL Users, Using [1] as a template, I built a ProbabilityScale[2] which I hope one day will be in the statsmodels library. It still needs some work, but it's mostly there. I have, what I hope is a basic question: Do I have to register the scale in order to use it, or is there an axes method to

Re: [Matplotlib-users] xkcd

2014-10-03 Thread Paul Hobson
That's what the `with` statement allows you do. Say you have a function that does some plotting and returns a figure -- call it my_plot_func. You can do: fig1 = my_plot_func() fig1.savefig('normal1.png') with plt.xkcd(): fig2 = mu_plot_func() fig2.savefig('xkcd.png') fig2 =

Re: [Matplotlib-users] seg fault installing

2014-10-01 Thread Paul Hobson
You mean matplotlib 1.3.1 and numpy 1.8.1, right?-- Paul Hobson Sorry if this is unintelligible. I'm on my phone. On Wed, Oct 1, 2014 at 9:36 AM, Steve McAfee smcafee.soc...@gmail.com wrote: This is really old. It's a readynas from netgear running etch with a bunch of backports. It seems

Re: [Matplotlib-users] zoom a plot

2014-09-15 Thread Paul Hobson
I don't think you'll get acceptable performance out of that workflow. I recommend looking into the webagg backend: http://matplotlib.org/users/whats_new.html#webagg-backend On Mon, Sep 15, 2014 at 8:38 AM, Xiaobo Yang xiaobo.y...@gmail.com wrote: Hi, I use matplotlib to create a png file, then

Re: [Matplotlib-users] zoom a plot

2014-09-15 Thread Paul Hobson
Yes. They are on the same webpage to which I linked earlier. http://matplotlib.org/search.html?q=codex+webaggcheck_keywords=yesarea=default On Mon, Sep 15, 2014 at 9:28 AM, Tom Young xiaobo.y...@gmail.com wrote: Thank you for your quick answer. I understand the performance issue you

Re: [Matplotlib-users] (no subject)

2014-09-05 Thread Paul Hobson
How do you do this in a normal LaTeX document? On Fri, Sep 5, 2014 at 12:53 PM, Arnaldo Russo arnaldoru...@gmail.com wrote: Hi, I'm trying to figure out how I could use greek letters on axis labels, without italic. I have read a lot about alternatives, but I do need to use LaTeX to insert

Re: [Matplotlib-users] Pick a particular data from array

2014-06-17 Thread Paul Hobson
Based on the example you posted, you need like: import matplotlib.pyplot as plt fig, ax = plt.subplots() ax.contour(data) ax.axhline(magic_value) On Mon, Jun 16, 2014 at 1:30 AM, dydy2014 dyahr...@gmail.com wrote: Hello all, I have contour plot like this and I have problem to pick a

Re: [Matplotlib-users] matplot crases because of XDG_CONFIG_HOME variable

2014-05-07 Thread Paul Hobson
How did you install matplotlib? I've had success using anaconda on cheap $7/month web servers before http://continuum.io/downloads On Wed, May 7, 2014 at 7:20 AM, Paul Tremblay paulhtremb...@gmail.comwrote: I am using matplotllib as part of web server. matplotlib causes my server to crash

Re: [Matplotlib-users] Which api to learn?

2014-04-30 Thread Paul Hobson
The only pyplot function I let myself use is plt.subplots() to quickly create the Figure and Axes objects. From that point on, I operate on those objects directly. Frankly, it reads almost exactly like pyplot code, but it is a *lot* more clear what's going on. On Wed, Apr 30, 2014 at 4:49 AM,

Re: [Matplotlib-users] installation problem

2014-04-29 Thread Paul Hobson
As the error says, you need the dateutil package. It available here: http://www.lfd.uci.edu/~gohlke/pythonlibs/#python-dateutil On Mon, Apr 28, 2014 at 11:10 PM, Stam Golesh stamgol...@gmail.com wrote: hi all downloaded and installed matplotlib-1.3.1.win32-py3.2.exe this is what i get

Re: [Matplotlib-users] datestr2num for day/month/year

2014-04-25 Thread Paul Hobson
You might have more luck reading in that data (dates with mixed format) with pandas than numpy. On Fri, Apr 25, 2014 at 2:37 AM, Mark Bakker mark...@gmail.com wrote: Thanks, Andreas, but it doesn't quite work. This works for me (I manually changed all dates to 'day-month-year' for

Re: [Matplotlib-users] Make clear figure used in the powerpoint slides?

2014-04-20 Thread Paul Hobson
What parameters are you passing to `savefig`? On Sat, Apr 19, 2014 at 1:13 PM, Chao YUE chaoyue...@gmail.com wrote: Dear all, Did anyone try to make plots using matplotlib, and then put the figure in the powerpoint for presentation? Currently I am using the ipython notebook --pylab mode to

Re: [Matplotlib-users] Variable size markers legend formatting

2014-04-11 Thread Paul Hobson
, 2014 at 2:20 PM, Adam Hughes hughesada...@gmail.com wrote: Thanks Paul, I will try it out. On Wed, Apr 9, 2014 at 12:21 PM, Paul Hobson pmhob...@gmail.com wrote: On Wed, Apr 9, 2014 at 9:00 AM, Adam Hughes hughesada...@gmail.com wrote: Thanks. That's probably the way I'll go

Re: [Matplotlib-users] Install under Win 7

2014-04-11 Thread Paul Hobson
You should be using conda to install matplotlib: conda create --name mpl33 matplotlib python=3.3 ipython-notebok source activate mpl33 On Fri, Apr 11, 2014 at 8:11 AM, grivet gri...@cnrs-orleans.fr wrote: Under Win7pro, I have tried to install matplotlib by running either

Re: [Matplotlib-users] Install under Win 7

2014-04-11 Thread Paul Hobson
You're on windows, so that last command is just activate mpl33 On Fri, Apr 11, 2014 at 7:05 PM, Paul Hobson pmhob...@gmail.com wrote: You should be using conda to install matplotlib: conda create --name mpl33 matplotlib python=3.3 ipython-notebok source activate mpl33 On Fri, Apr 11

Re: [Matplotlib-users] Variable size markers legend formatting

2014-04-09 Thread Paul Hobson
On Wed, Apr 9, 2014 at 9:00 AM, Adam Hughes hughesada...@gmail.com wrote: Thanks. That's probably the way I'll go. At first, I thought creating separate legend markers and removing them from the plot seemed hacky, but I guess there's no way that matplotlib could know which legend size I

Re: [Matplotlib-users] Is there interrest for an implementation of colour maps visualising small differences around 0

2014-03-14 Thread Paul Hobson
Pål, Matplotlib already has a jet colormap and has moved away from using it as the default for the very reasons listed in the first paper you site. How is your jet colormap different? Can you provide a comparison with the existing colormap? Does it overcome the drawbacks listed in the Sandia

Re: [Matplotlib-users] multiplot in a for loop

2014-03-10 Thread Paul Hobson
Gabriele, I'm confused. I only see 1 series in each subplot. Could you trim your example down into some code that we can copy, paste, and run? A more thorough description of the problem might help too. -p On Mon, Mar 10, 2014 at 9:39 AM, Gabriele Brambilla gb.gabrielebrambi...@gmail.com wrote:

Re: [Matplotlib-users] multiplot in a for loop

2014-03-10 Thread Paul Hobson
Paul Hobson pmhob...@gmail.com: Gabriele, I'm confused. I only see 1 series in each subplot. Could you trim your example down into some code that we can copy, paste, and run? A more thorough description of the problem might help too. -p On Mon, Mar 10, 2014 at 9:39 AM, Gabriele Brambilla

Re: [Matplotlib-users] imshow for .png- low resultion

2014-03-05 Thread Paul Hobson
Olga Botnivik is doing some work with these types of figures in her fork of the seaborn project. Example here: http://nbviewer.ipython.org/gist/olgabot/8341784 Link to the PR in github: https://github.com/mwaskom/seaborn/pull/73 Those might be a good place to start. On Wed, Mar 5, 2014 at

Re: [Matplotlib-users] Loding CSV file and plotting histogram of a particular column

2014-02-28 Thread Paul Hobson
Sounds like you want to use pandas, not numpy. import pandas import matplotlib.pyplot as plt df = pandas.read_csv('myfile.txt', sep='\t') plt.hist(data['A'], bins=30) ...should do it for you. On Fri, Feb 28, 2014 at 11:06 AM, AR12 aarthi.re...@gmail.com wrote: Hi, I have a csv file where

Re: [Matplotlib-users] grid of subplot

2014-02-23 Thread Paul Hobson
You're not adding your subplot to an existing figure, so a new one is created. put fig = plt.figure(...) at the top of your script and replace axii = plt.subplot(numalp, numobs, axisNum) with axii = fig.add_subplot(numalp, numobs, axisNum) On Sat, Feb 22, 2014 at 5:28 PM, Gabriele Brambilla

Re: [Matplotlib-users] [os x] Can't get IPython to use latest version of matplotlib

2014-02-21 Thread Paul Hobson
It appears that you have two different version of python installed (Apple's 2.7.3 and python.org's 2.7.5). You have to install all third-party packages to the correct one. It appears pip in acting on Apple's python. On Fri, Feb 21, 2014 at 2:08 PM, Timothy Duly timdu...@gmail.com wrote: Hello,

Re: [Matplotlib-users] colorbllind problem

2014-02-18 Thread Paul Hobson
-02-17 20:57 GMT-05:00 Paul Hobson pmhob...@gmail.com: Untested, of course, but I would do something like this: import matplotlib.pyplot as plt import seaborn N = len(As) myPallette = seaborn.color_palette(skyblue, N) # use the name of any mpl colormap here seaborn.set_color_pallette

Re: [Matplotlib-users] colorbllind problem

2014-02-17 Thread Paul Hobson
Adam, Look into the seaborn project: http://nbviewer.ipython.org/github/mwaskom/seaborn/blob/master/examples/aesthetics.ipynb it's easy enough to define your own color palettes or select existing ones. -paul On Mon, Feb 17, 2014 at 11:41 AM, Adam Hughes hughesada...@gmail.comwrote: I'm

Re: [Matplotlib-users] colorbllind problem

2014-02-17 Thread Paul Hobson
(bbox_to_anchor=(1.05, 1), loc=9, borderaxespad=0.) lotgr.canvas.draw() thanks Gabriele 2014-02-17 14:46 GMT-05:00 Paul Hobson pmhob...@gmail.com: Adam, Look into the seaborn project: http://nbviewer.ipython.org/github/mwaskom/seaborn/blob/master/examples/aesthetics.ipynb it's easy

Re: [Matplotlib-users] plotting two functions on the same figure but with two different scales on y axis

2014-02-14 Thread Paul Hobson
Hey Gabriele, See this example here: http://stackoverflow.com/questions/14762181/adding-a-y-axis-label-to-secondary-y-axis-in-matplotlib/14762601#14762601 On Fri, Feb 14, 2014 at 12:32 PM, Gabriele Brambilla gb.gabrielebrambi...@gmail.com wrote: Hi, I'm trying to plot two functions on the

Re: [Matplotlib-users] Documentation for mpl_toolkits.basemap

2014-02-13 Thread Paul Hobson
It's not the wrong place, per se. But I think if you created an issue on the github repository, it's less likely to get lost in the ether. https://github.com/matplotlib/basemap On Wed, Feb 12, 2014 at 7:17 PM, Roman Olson roman.ol...@unsw.edu.auwrote: Hi All, I am new to this list so I

Re: [Matplotlib-users] Plotting a series of 3d quadrilaterals as a wireframe

2014-02-05 Thread Paul Hobson
Not quite sure exactly what you need to do, but it sounds like separate calls to `plot` for each quadrilateral will do the trick. -paul On Wed, Feb 5, 2014 at 4:57 PM, Pedro Marcal pedrovmar...@gmail.com wrote: I don't know how to separately plot the quadrilaterals after plotting each of them

Re: [Matplotlib-users] Plotting NOAA grib2 data in basemap

2014-01-09 Thread Paul Hobson
As the error message says, the problem is on Line 14: print f.variables['WWSWHGT_P0_L1_GLL0'] a KeyError means that you tried to access an element that is not in a dictionary. In this case f.variables is the dictionary and ' WWSWHGT_P0_L1_GLL0' is the element. Did your data and script come of

Re: [Matplotlib-users] Plotting NOAA grib2 data in basemap

2014-01-09 Thread Paul Hobson
I think you posted the same image in both cases. Without seeing the problematic image, I can only guess that it's caused by the resolution of your data. On Thu, Jan 9, 2014 at 7:58 AM, A Short surfersh...@hotmail.com wrote: Hi Paul, Thanks for your reply, I managed to fix it after I realised

Re: [Matplotlib-users] Plotting NOAA grib2 data in basemap

2014-01-09 Thread Paul Hobson
What I'm saying is that your top image and bottom image are identical and I don't see any white boxes in either. What is the resolution of the grid? -paul On Thu, Jan 9, 2014 at 11:59 AM, A Short surfersh...@hotmail.com wrote: ok the file im using is this multi_2.glo_30m.t06z.grib2 from here

Re: [Matplotlib-users] Plotting NOAA grib2 data in basemap

2014-01-09 Thread Paul Hobson
How does it look if you remove the calls to `m.drawcoastlines()` and ` m.fillcontinents()`? On Thu, Jan 9, 2014 at 1:05 PM, A Short surfersh...@hotmail.com wrote: Thats strange they look different on this browser. Hopefully the one below youll see what i mean Thanks

Re: [Matplotlib-users] Plotting NOAA grib2 data in basemap

2014-01-09 Thread Paul Hobson
Looks like it's just a coarse resolution to me. Try showing the data as an image with no iterpolation. On Thu, Jan 9, 2014 at 3:26 PM, A Short surfersh...@hotmail.com wrote: Ive also changed the grib file from multi_2.glo_30m.t06z.grib2 to nww3.t12z.grib.grib2 i still cant figure out which is

Re: [Matplotlib-users] Interative legend manipulation?

2014-01-07 Thread Paul Hobson
I believe (as of v1.3.1) that after you create the legend you call leg.draggable(True) http://matplotlib.org/api/legend_api.html#matplotlib.legend.Legend.draggable On Tue, Jan 7, 2014 at 6:37 AM, Skip Montanaro s...@pobox.com wrote: Sometimes the legend simply gets in the way. You can't

Re: [Matplotlib-users] Most generic way to wrap collections

2014-01-07 Thread Paul Hobson
Adam, Not sure if this is the try you're trying to bark up, but I've used a total hack to do what I think you're describing: 1) store lists of coordinate pairs in a pandas DataFrame 2) use df.apply() to turn each list of coords in to a patch and add to an axes object I'm sure you know this,

Re: [Matplotlib-users] Nanoseond timestamp on x axis

2013-12-19 Thread Paul Hobson
Here are a couple of examples of using custom formats: http://matplotlib.org/examples/api/date_index_formatter.html http://matplotlib.org/examples/pylab_examples/date_demo2.html And here's a link with all of the possible formatting strings: http://www.tutorialspoint.com/python/time_strftime.htm

Re: [Matplotlib-users] Normalizing Marker Size in Legend

2013-12-05 Thread Paul Hobson
Matthew, I think you're on the right track. You need proxy artists of some sort. You can create Line2D objects directly, never add them to the figure, and then use those to create the legend. An alternatively/hacky approach I often use is to the plot all the real data with '_nolegend' labels,

Re: [Matplotlib-users] axes labelling

2013-11-23 Thread Paul Hobson
Hey Sourav, This example should demonstrate the basics of setting xticks and xticklabels http://matplotlib.org/examples/ticks_and_spines/ticklabels_demo_rotation.html On Sat, Nov 23, 2013 at 4:27 AM, Sourav Chatterjee srv@gmail.comwrote: Hi, I have simple xy plot using below. import

Re: [Matplotlib-users] indicating directions on stereographic projection.

2013-11-06 Thread Paul Hobson
On Wed, Oct 23, 2013 at 9:30 PM, Sourav Chatterjee srv@gmail.comwrote: Hello, I have stereographic projection of the pole. I need to indicate the directions like north,south,east, west, north-east, north-west and so on. Is there any way to do so? Thanks Sourav I am **very far** from

Re: [Matplotlib-users] x axis non-uniform labeling (KURT PETERS)

2013-10-01 Thread Paul Hobson
On Mon, Sep 30, 2013 at 4:50 PM, KURT PETERS petersk...@msn.com wrote: That doesn't seem to fix it. What I'm expecting is at the top, 28 should correspond to the value -2. Instead it puts a 30 there. Kurt It's not really clear to me what you're trying to do. But the rounding of the axes

Re: [Matplotlib-users] x axis non-uniform labeling (KURT PETERS)

2013-09-30 Thread Paul Hobson
On Mon, Sep 30, 2013 at 1:43 PM, KURT PETERS petersk...@msn.com wrote: I'm including the code below to demonstrate the problem. The top should have simtimedata (0 through 28) labeling the points. As you can see, MATPLOTLIB just distributes those values evenly instead of assigning them

Re: [Matplotlib-users] [matplotlib-devel] I have a Mac!

2013-08-16 Thread Paul Hobson
Mike, That's great news. Is there any chance we can look forward to official instructions for setting up a Mac to develop matplotlib? I gave up a long time ago and started piecing to together my meager PRs in a linux VM. -paul On Fri, Aug 16, 2013 at 6:52 AM, Michael Droettboom md...@stsci.edu

Re: [Matplotlib-users] Font in figures needs to load a specific latex package \usepackage{tipa}

2013-07-25 Thread Paul Hobson
On Thu, Jul 25, 2013 at 12:16 PM, Jeffrey Spencer jeffspenc...@gmail.comwrote: I want to use IPA vowel labels in my figures and to do that I need to load the package in latex \usepackage{tipa}. Is this possible as searching online besides using the new backend pgf I haven't seen how to

Re: [Matplotlib-users] Asking for help modifying a matplot windrose graphic using Python (:

2013-07-22 Thread Paul Hobson
Guilherme, Check out my implementation of windroses here: https://github.com/phobson/python-metar/blob/master/metar/graphics.py#L138 On Mon, Jul 22, 2013 at 11:54 AM, Guilherme Araújo Martins gami...@globo.com wrote: Hello guys. I'm having a problem with a matplot graphic and I guess it can

Re: [Matplotlib-users] savefig

2013-06-14 Thread Paul Hobson
On Thu, Jun 13, 2013 at 11:40 PM, Sudheer Joseph sudheer.jos...@yahoo.comwrote: Thank you, I don't see a way other than starting in normal mode as the moment I type plot command it get displayed and I don't need to do a show command. In the qtconsole, you can enter multi-line mode with

Re: [Matplotlib-users] full grid for 2nd y-axis wit twinx() ?

2013-06-14 Thread Paul Hobson
On Thu, Jun 13, 2013 at 1:33 PM, Daniel Mader danielstefanma...@googlemail.com wrote: Hi Paul, I've modified your suggestion a little, since I don't want a grid for the primary axis at all -- unfortunately to no avail, i.e. no grid line at all: import numpy import matplotlib

Re: [Matplotlib-users] full grid for 2nd y-axis wit twinx() ?

2013-06-13 Thread Paul Hobson
On Thu, Jun 13, 2013 at 4:47 AM, Daniel Mader danielstefanma...@googlemail.com wrote: Hi, I need a twinx() plot with horizontal and vertical grid lines for the second axis, just like the usual grid for the first axis. I don't need or want to specify the ticks manually, though! My example

Re: [Matplotlib-users] time axis format

2013-06-10 Thread Paul Hobson
sudheer.jos...@yahoo.com *To:* Paul Hobson pmhob...@gmail.com *Cc:* matplotlib-users@lists.sourceforge.net matplotlib-users@lists.sourceforge.net *Sent:* Saturday, 8 June 2013 7:46 PM *Subject:* Re: [Matplotlib-users] time axis format Thank you Paul for the helping hand

Re: [Matplotlib-users] time series

2013-06-05 Thread Paul Hobson
On Wed, Jun 5, 2013 at 9:13 AM, Sudheer Joseph sudheer.jos...@yahoo.comwrote: Dear Users, Is there any other method in matplotlib to get the plot similar to the one there in below link? http://dsnra.jpl.nasa.gov/software/Python/scikits/lib.plotting.examples.html I tried

Re: [Matplotlib-users] why legend does not show in matplotlib-1.2.1 py2.7

2013-05-23 Thread Paul Hobson
Sorry I have to be so brief, but just like the error says, you fed the legend function the wedges returned by the pie command. But legend can't handle wedges. As the proxy artist tutorial hints, you need to feed it rectangles created manually (i.e., outside of any plotting commands). Hope that

Re: [Matplotlib-users] missing ticks on inverted log axis

2013-05-15 Thread Paul Hobson
On Wed, May 15, 2013 at 3:48 PM, gaspra yes2...@gmail.com wrote: Hi, I am having troubles to correctly make a figure with inverted log axis. This is what I am doing: import numpy as np import matplotlib.pyplot as plt y=np.linspace(-90,90,20) z=np.arange(1,1.e4, 200)

Re: [Matplotlib-users] Problems with sans-serif fonts and tick labels with TeX

2013-05-03 Thread Paul Hobson
On Fri, May 3, 2013 at 6:17 AM, Michael Droettboom md...@stsci.edu wrote: On 05/02/2013 03:16 PM, Paul Hobson wrote I now see that this was more of TeX issue than an MPL configuration issue. Your help prompted me to find this solution (similar to yours): mpl.rcParams

Re: [Matplotlib-users] Problems with sans-serif fonts and tick labels with TeX

2013-05-02 Thread Paul Hobson
On Thu, May 2, 2013 at 11:19 AM, Michael Droettboom md...@stsci.edu wrote: I think the confusion here stems from the fact that you're mixing TeX and non-TeX font commands. This turns on TeX mode, so all of the text is rendered with an external TeX installation: rc('text', usetex=True)

Re: [Matplotlib-users] windrose

2013-03-19 Thread Paul Hobson
On Tue, Mar 19, 2013 at 2:22 AM, Sudheer Joseph sudheer.jos...@yahoo.comwrote: Dear users, Attached is a windrose diagram created by using https://sourceforge.net/project/showfiles.php?group_id=239240package_id=290902. Can any one tell me if the numbers displayed in

Re: [Matplotlib-users] Aligning xticks and labels with WeekdayLocator

2013-03-19 Thread Paul Hobson
On Mon, Mar 18, 2013 at 8:34 PM, Mark Lawrence breamore...@yahoo.co.ukwrote: Matplotlib 1.2.0, Windows Vista, Python 3.3.0. I want the first major xtick label aligned with the first date that's plotted. This never happens with the value of day below set in the range zero to six. The first

Re: [Matplotlib-users] Aligning xticks and labels with WeekdayLocator

2013-03-19 Thread Paul Hobson
On Tue, Mar 19, 2013 at 11:30 AM, Paul Hobson pmhob...@gmail.com wrote: On Mon, Mar 18, 2013 at 8:34 PM, Mark Lawrence breamore...@yahoo.co.ukwrote: Matplotlib 1.2.0, Windows Vista, Python 3.3.0. I want the first major xtick label aligned with the first date that's plotted. This never

Re: [Matplotlib-users] Evolution of the interface

2013-03-15 Thread Paul Hobson
On Fri, Mar 15, 2013 at 8:01 AM, Christophe BAL projet...@gmail.com wrote: Hello, I really appreciate the work done by matplotlib but I really think that the interface must evolve. Here is a small example. *object.set_something(...)* *object.get_something()* It could be easier to

Re: [Matplotlib-users] boxplot

2013-03-14 Thread Paul Hobson
On Thu, Mar 14, 2013 at 12:40 AM, paul.czodrow...@merckgroup.com wrote: Dear Matplotlibbers, I'm running matplotlib 1.1.0 and would like to plot pairs of values, e.g. [[0.27,0.43],[0.17,0.35]] When using boxplot, the values of the pairs correspond to the outer whiskers, but I would like

Re: [Matplotlib-users] data format question

2013-03-06 Thread Paul Hobson
On Wed, Mar 6, 2013 at 2:00 PM, Clifford Lyon clifford.l...@gmail.comwrote: I wish to make a boxplot with data in this format: Value, Frequency 0, 128329 1, 20390 2, 230 3, 32 4, 3 etc. Rather than expand this into a flat array, is there some way to pass in weights for values? Some

Re: [Matplotlib-users] View datetime corresponding to x coordinate of cursor

2013-03-04 Thread Paul Hobson
On Mon, Mar 4, 2013 at 11:23 AM, William Furnass w...@thearete.co.ukwrote: Several backends will show you the x and y float values that correspond to the current cursor position in a plot() but are there backends that show the _datetime_ corresponding to the x position if the plotted data is

Re: [Matplotlib-users] changing the shade of a color depending on a value

2013-02-27 Thread Paul Hobson
On Wed, Feb 27, 2013 at 1:49 AM, Rita rmorgan...@gmail.com wrote: Hi, I am currently plotting cpu utilization over time (plot_time). I would like the color of my line to be red when at 100%. 80-90% a bit less red, more yellow, and lower numbers will be green. Any thoughts of doing this? A

Re: [Matplotlib-users] cross correlation

2013-02-27 Thread Paul Hobson
On Wed, Feb 27, 2013 at 1:01 AM, Sudheer Joseph sudheer.jos...@yahoo.comwrote: Dear Pierre, I was checking the plt.xcorr and it calls the np.correlate in side it. It calls np.correlate(ts1,ts2, mode=2). Is there a way to see which vector is sided back in time? ie

  1   2   >