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

2014-04-30 Thread Michiel de Hoon
99.9% of the time I am using pyplot, as it usually does what I want without me 
having to understand an api.
I don't care so much if pyplot agrees with matlab or not, but it should be 
something easy that new users can pick up quickly.

Best,
-Michiel


On Wed, 4/30/14, Neal Becker  wrote:

 Subject: [Matplotlib-users] Which api to learn?
 To: matplotlib-users@lists.sourceforge.net
 Date: Wednesday, April 30, 2014, 7:49 AM
 
 I've never used matlab (and hope
 never to have to).  But I've been using pyplot 
 api for mpl for quite a while.
 
 Is there any good reason to move to the "native" mpl api and
 drop pyplot?  I ask 
 because as I understand, pyplot is intended as a matlab
 workalike, and since I 
 never learned matlab I have no need for that crutch. 
 OTOH, I'm quite used to 
 the pyplot api at this point.
 
 
 --
 "Accelerate Dev Cycles with Automated Cross-Browser Testing
 - For FREE
 Instantly run your Selenium tests across 300+ browser/OS
 combos.  Get 
 unparalleled scalability from the best Selenium testing
 platform available.
 Simple to use. Nothing to install. Get started now for
 free."
 http://p.sf.net/sfu/SauceLabs
 ___
 Matplotlib-users mailing list
 Matplotlib-users@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/matplotlib-users
 

--
"Accelerate Dev Cycles with Automated Cross-Browser Testing - For FREE
Instantly run your Selenium tests across 300+ browser/OS combos.  Get 
unparalleled scalability from the best Selenium testing platform available.
Simple to use. Nothing to install. Get started now for free."
http://p.sf.net/sfu/SauceLabs
___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users


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

2014-04-30 Thread Neal Becker
Paul Hobson wrote:

> 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.
> 
...

Actually this is going to be harder than I thought.  Looking around for some 
examples of API not using pyplot I'm not turning up much.  If I look at 
http://matplotlib.org/api/index.html

I quickly find myself staring at pyplot docs, and if I look at a few 
http://matplotlib.org/examples/index.html

I see pyplot examples.

Where would I find non-pyplot examples and docs?


--
"Accelerate Dev Cycles with Automated Cross-Browser Testing - For FREE
Instantly run your Selenium tests across 300+ browser/OS combos.  Get 
unparalleled scalability from the best Selenium testing platform available.
Simple to use. Nothing to install. Get started now for free."
http://p.sf.net/sfu/SauceLabs
___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users


[Matplotlib-users] Visible image joins

2014-04-30 Thread Hattersley, Richard
Hi,

I'm trying to display a mosaic of image tiles in a single plot, but I keep
getting lines between the tiles. Is there a way to avoid these lines?
(I'd really rather not pre-process the images to stitch them all together
into a single image.)


The following code reproduces the problem:

 
import matplotlib.pyplot as plt
import numpy as np
 
e1 = (27, 31.5, 31.5, 36)
e2 = (31.5, 36, 31.5, 36)
 
image = np.zeros((10, 10))
for e in (e1, e2):
plt.imshow(image, extent=e)
plt.xlim(27, 36)
plt.show()


I've also tried the following with no improvement:
plt.imshow(image, extent=e, interpolation='none', resample=False)


Thanks,
Richard Hattersley

--
"Accelerate Dev Cycles with Automated Cross-Browser Testing - For FREE
Instantly run your Selenium tests across 300+ browser/OS combos.  Get 
unparalleled scalability from the best Selenium testing platform available.
Simple to use. Nothing to install. Get started now for free."
http://p.sf.net/sfu/SauceLabs
___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users


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, Neal Becker  wrote:

> I've never used matlab (and hope never to have to).  But I've been using
> pyplot
> api for mpl for quite a while.
>
> Is there any good reason to move to the "native" mpl api and drop pyplot?
>  I ask
> because as I understand, pyplot is intended as a matlab workalike, and
> since I
> never learned matlab I have no need for that crutch.  OTOH, I'm quite used
> to
> the pyplot api at this point.
>
>
>
> --
> "Accelerate Dev Cycles with Automated Cross-Browser Testing - For FREE
> Instantly run your Selenium tests across 300+ browser/OS combos.  Get
> unparalleled scalability from the best Selenium testing platform available.
> Simple to use. Nothing to install. Get started now for free."
> http://p.sf.net/sfu/SauceLabs
> ___
> Matplotlib-users mailing list
> Matplotlib-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/matplotlib-users
>
--
"Accelerate Dev Cycles with Automated Cross-Browser Testing - For FREE
Instantly run your Selenium tests across 300+ browser/OS combos.  Get 
unparalleled scalability from the best Selenium testing platform available.
Simple to use. Nothing to install. Get started now for free."
http://p.sf.net/sfu/SauceLabs___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users


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

2014-04-30 Thread Benjamin Root
I wrote up my answer to this question on stackoverflow once:
https://stackoverflow.com/questions/19895262/when-to-use-the-matplotlib-pyplot-class-and-when-to-use-the-plot-object-matplot/21004357#21004357

Others may have different opinions or variations on the theme, but this is
how I look at the issue. It is also the reason why I don't want to
deprecate pylab (but do want to keep it out of examples).

Cheers!
Ben Root



On Wed, Apr 30, 2014 at 7:49 AM, Neal Becker  wrote:

> I've never used matlab (and hope never to have to).  But I've been using
> pyplot
> api for mpl for quite a while.
>
> Is there any good reason to move to the "native" mpl api and drop pyplot?
>  I ask
> because as I understand, pyplot is intended as a matlab workalike, and
> since I
> never learned matlab I have no need for that crutch.  OTOH, I'm quite used
> to
> the pyplot api at this point.
>
>
>
> --
> "Accelerate Dev Cycles with Automated Cross-Browser Testing - For FREE
> Instantly run your Selenium tests across 300+ browser/OS combos.  Get
> unparalleled scalability from the best Selenium testing platform available.
> Simple to use. Nothing to install. Get started now for free."
> http://p.sf.net/sfu/SauceLabs
> ___
> Matplotlib-users mailing list
> Matplotlib-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/matplotlib-users
>
--
"Accelerate Dev Cycles with Automated Cross-Browser Testing - For FREE
Instantly run your Selenium tests across 300+ browser/OS combos.  Get 
unparalleled scalability from the best Selenium testing platform available.
Simple to use. Nothing to install. Get started now for free."
http://p.sf.net/sfu/SauceLabs___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users


[Matplotlib-users] Which api to learn?

2014-04-30 Thread Neal Becker
I've never used matlab (and hope never to have to).  But I've been using pyplot 
api for mpl for quite a while.

Is there any good reason to move to the "native" mpl api and drop pyplot?  I 
ask 
because as I understand, pyplot is intended as a matlab workalike, and since I 
never learned matlab I have no need for that crutch.  OTOH, I'm quite used to 
the pyplot api at this point.


--
"Accelerate Dev Cycles with Automated Cross-Browser Testing - For FREE
Instantly run your Selenium tests across 300+ browser/OS combos.  Get 
unparalleled scalability from the best Selenium testing platform available.
Simple to use. Nothing to install. Get started now for free."
http://p.sf.net/sfu/SauceLabs
___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users


Re: [Matplotlib-users] Interactively get readable(i.e. lng/lat) coordinates from a matplotlib basemap plot?

2014-04-30 Thread Jonathan_Kowalik
I already got the answer:

ax = plt.gca()
def format_coord(x, y):
return 'x=%.4f, y=%.4f'%(m(x, y, inverse = True))
ax.format_coord = format_coord

This does exactly what I wanted. :-)



--
View this message in context: 
http://matplotlib.1069221.n5.nabble.com/Interactively-get-readable-i-e-lng-lat-coordinates-from-a-matplotlib-basemap-plot-tp43328p43330.html
Sent from the matplotlib - users mailing list archive at Nabble.com.

--
"Accelerate Dev Cycles with Automated Cross-Browser Testing - For FREE
Instantly run your Selenium tests across 300+ browser/OS combos.  Get 
unparalleled scalability from the best Selenium testing platform available.
Simple to use. Nothing to install. Get started now for free."
http://p.sf.net/sfu/SauceLabs
___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users