Re: [Matplotlib-users] Basemap contourf question

2010-07-14 Thread Benjamin Root
; It is just different then what I expected. I thought it would partition the > height field data based on the levels array and index into the color array. > Turning off antialiasing did not solve the 'ghost lines'. I will play around > with some of the arguments. It looks to m

Re: [Matplotlib-users] How to draw a region of interest

2006-08-07 Thread Daniel Kornhauser
region with a color - make it work with layers - add methods that return the pixel region or the contour coordinates - make a nice class If anybody has made such a widget I would love to see the code, I hate reinventing the wheel. If there is not such an example such as the lasso tool

[Matplotlib-users] One colorbar for many plot

2014-05-20 Thread Dyah rahayu martiningrum
- pn[ibeam][it] - 10.*np.log10(nfft) p_plot = p_plot.transpose() #Specify subplot pl.subplot(311 + i)#Contour plot pl.contourf(tim, rng, p_plot)#Plot colorbar pl.colorbar() # Set X and Y axis lower/upper limit set_xy = range(4) set_xy[0] = 18.0 # x min set_xy[1] = 30.0

Re: [Matplotlib-users] Easiest way to create a chloropleth in Python

2014-10-24 Thread Benjamin Root
ly, the interface should be similar to how contour maps or pseudocolor > plots are created where, at the minimum, only one call to a function is > needed to create these plots from data. Colors are automatically assigned > and normalized based on values. A colorbar can then be added by

Re: [Matplotlib-users] Problem extending a custom colormap

2014-11-03 Thread Eric Firing
nal segment on the > extended ends of the colorbar is the same color as the extension segment > (i.e. the bit in the little arrow). This happens even when hex_list is > much longer than the actual number of segments required. You need to use the "levels" kwarg to specify the c

[Matplotlib-users] Multiplot with one colorbar

2015-03-06 Thread Dyah rahayu martiningrum
netCDF file fd.close() # Specify beam ibeam = ibeams[i] # Time convertion tim = tim/3600.0 #Plot p_plot = pwr[ibeam] for it in range(len(tim)): p_plot[it] = p_plot[it] - pn[ibeam][it] - 10.*np.log10(nfft) p_plot = p_plot.transpose() #Specify subplot pl.sub

Re: [Matplotlib-users] Use _cntr.so in fortran?

2015-06-25 Thread Benjamin Root
e, as I think it has some contouring algorithms that might be easier to link to. Ben Root On Thu, Jun 25, 2015 at 2:28 PM, Sterling Smith wrote: > The contour finder in matplotlib is more robust than I currently have in a > legacy fortran project. I would like to link to matplotlib’s in

Re: [Matplotlib-users] Quiver not respecting hold state

2008-06-11 Thread Eric Firing
Marshall, You are right--there is a line of boilerplate that I left out of quiver, contour, and contourf. At the very top of each of these methods in axes.py there should be the line if not self._hold: self.cla() You can either add the line to your axes.py, or just do the manual pylab cla

Re: [Matplotlib-users] Basemap to KML polygon

2008-07-23 Thread Scott Sinclair
egrees of lat and lon, then all you need to do is write a simple text file to specify where Google Earth should display your Basemap contour map. What you're doing does sound more elegant, but more complex. Regard

Re: [Matplotlib-users] colorbar() fix limit on Heat map

2008-08-11 Thread Jeff Whitaker
(blue - red). > > I have tried things like colorbar(0,1), however no luck. > > If you could let me know how to fix the range, I would be very grateful. > > Regards > Stuart: Use the vmin/vmax keyword arguments if your are using imshow or pcolor/pcolormesh. If you are using co

[Matplotlib-users] Generating an isosurface (mesh) out of a 3d array [SEC=UNCLASSIFIED]

2008-08-21 Thread Scott Collis
it could be done by generating contours on constant Z slices of the cube and then searching for the closest vertices of the contour below it to make meshes... I have played with MayaVI but have run into a few issues with it. (happy to receive recommendations of other 3D Vis environments compatible

[Matplotlib-users] Using the same color range for multiple plots

2009-03-18 Thread cneff
Hi guys, I've tried to google this and look through the examples but its not quite working for me. Say I have two sets of data I want to make contour plots out of from pylab import * x=arange(-3.0,3.0,.025) y=arange(-2.0,2.0,.025) X,Y = meshgrid(x,y) Z1 = mlab.bivariate_normal(X, Y

[Matplotlib-users] bug in fcontour with v1.1.0 ?

2011-12-05 Thread Arnaud
6', edgecolor='k') ax = fig.gca() cmap=get_cmap('reds') plage = arange(0,100,1) surf = contourf(X,Y,F, plage) plage = arange(0,100,2) surf = contour(X,Y,F, plage, linewidths=2) ax.grid(True) fig.colorbar(surf, shrink=0.5, aspect=5) axis([x.min(),x.max(),y.min(),y.max()])

Re: [Matplotlib-users] sharex with different tick labels

2012-09-17 Thread Stan West
From: Daniel Welling [mailto:dantwell...@gmail.com] Sent: Thursday, September 13, 2012 16:23 Greetings, all. I have an issue: I have several axes stacked in a column with a common time vector on each x-axis. Each plot is a contour, so overplotting is not an option. In a perfect world, I want

[Matplotlib-users] ANN: matplotlib 1.2.0

2012-11-08 Thread Michael Droettboom
ere is new support for outputting PGF/TikZ files. New plot types include 3D trisurface plots, and streamplots. Tripcolor, boxplot, colorbars and contour plots have all grown new features. And under the hood, numerous improvements in stability, flexibility and robustness. For a complete lis

Re: [Matplotlib-users] contour3D custom levels possible?

2010-08-01 Thread Eric Firing
> > from mpl_toolkits.mplot3d import axes3d > import matplotlib.pyplot as plt > > fig = plt.figure() > ax = axes3d.Axes3D(fig) > X, Y, Z = axes3d.get_test_data(0.05) > cset = ax.contourf(X, Y, Z, 0)# doesn't work with contour This is a fluke. Try cset = ax.contour(

[Matplotlib-users] Exclude colour from a colourbar

2010-09-13 Thread mdekauwe
Hi, I am setting a colourbar where I explictly set the tick intervals. However I would like to exclude the colour black from this colourbar. The reason for this is I would like to overplot some contour lines in black, so would like to make them stand out. An example...where I would like to

Re: [Matplotlib-users] small patch to enable formatters for contour line labels

2011-02-20 Thread Eric Firing
On 02/20/2011 06:17 AM, Daniel Hyams wrote: > > The function "clabel" does not allow the use of formatters for the > label; this small patch enables their use, so that one can pass in any > subclass of ticker.Formatter in the 'fmt' argument. > > Replace the following in contour.py: > > def get_

Re: [Matplotlib-users] 3d Surface-Contour Plot

2011-03-28 Thread Nicolas Bigaouette
On Mon, Mar 14, 2011 at 9:05 AM, herbie13 wrote: > > Hello, > > I basically have a Chi-Squared distribution that is dependent on 3 > variables. > eg. X2(x, y, z) > > What I would like to do is be able to plot the chi-squared + 1 surface in > 3-dimensions. > eg. I would like to have the three axes

[Matplotlib-users] aspect_ratio in combination with sharex

2008-02-11 Thread Mark Bakker
thing wrong, or whether this can be fixed easily. When I make a small contour plot setting the aspect ratio equal works fine: from pylab import * x,y = meshgrid(linspace(0,5,5),linspace(0,5,5)) figure() ax = subplot(211) ax.contour(x,y,x) ax.set_aspect('equal',adjustable='datalim

Re: [Matplotlib-users] day-night terminator and/or solar zenith angle code ?

2008-02-13 Thread Jeff Whitaker
Jim Vickroy wrote: > Hello all, > > Could someone offer suggestions for (preferably) python code to compute: > > * day/night terminator position > * solar zenith angle > > > I'm developing a basemap application that is required to hide contour > dat

Re: [Matplotlib-users] raster in basemap

2008-02-27 Thread Lionel Roubeyrie
your help > > Lionel: You can use the set_xlim and set_ylim axes methods to manually > 'zoom' the plot. It has to be done after all the other plotting though, > since all the Basemap methods (contour, imshow etc) will reset the axes > limits to show the entire map region. >

Re: [Matplotlib-users] extend for colorbar

2006-08-22 Thread Philip Austin
ing * New: * * extend = 'neither', 'both', 'min', 'max' Unless this is 'neither' (default), contour levels are automatically added to one or both ends of the range so that all data are included.

Re: [Matplotlib-users] Plotting large file (NetCDF)

2014-09-09 Thread Ryan Nelson
nstead of pcolor() as they are more > way more efficient than pcolor(). In addition, it sounds like you are > dealing with re-sampled data ("at different zoom levels"). Does this mean > that you are re-running contour on re-sampled data? I am not sure what the > benefit

Re: [Matplotlib-users] Easiest way to create a chloropleth in Python

2014-10-24 Thread Christian Alis
been creating chloropleth maps in Python by adding patches and/or >> polygons in a matplotlib Axes but I'm looking for something easier to use. >> >> Ideally, the interface should be similar to how contour maps or >> pseudocolor >> plots are created where, at the min

Re: [Matplotlib-users] ploting a contour graph from data files

2008-07-16 Thread Eric Firing
Oz Nahum wrote: > Ok, I played with it a little bit. > > Here is what I know: > importing the data is not a big issue, I aready wrote a tutorial about > it here: > http://www.tabula0rasa.org/?p=21 > > here is a sample code I wrote. > from matplotlib import pyplot as plt > from pylab import * > t

Re: [Matplotlib-users] Just an aside question on Basemap

2008-12-09 Thread Jeff Whitaker
instance, i.e. x, y = m(lon, lat) # lon,lat can be arrays, lists or scalars. m is a Basemap instance. You then pass x,y to the plot command (be it 'plot', 'scatter', 'contour' or whatever). -Jeff -- Jeffrey S. Whitaker Phone : (303)497-6313 NOAA/OAR/CDC R/

Re: [Matplotlib-users] New OSX installers (beta)

2008-12-15 Thread John Hunter
On Mon, Dec 15, 2008 at 1:08 AM, Scott Lasley wrote: > Hello, > > I used your new beta installer to install matplotlib on a G5 running > OS X 10.5.5. I tried the contour demo and got this error > > pylab_examples$ pythonw contour_demo.py > Traceback (most recent

Re: [Matplotlib-users] Using the same color range for multiple plots

2009-03-18 Thread Eric Firing
cneff wrote: > Hi guys, > > I've tried to google this and look through the examples but its not quite > working for me. Say I have two sets of data I want to make contour plots out > of > > from pylab import * > > x=arange(-3.0,3.0,.025) > > y=arange(

Re: [Matplotlib-users] cross hatching in contours?

2011-09-17 Thread Jae-Joon Lee
; As far as I can tell, contour and contourf return objects of their own > type (contour.QuadContourSet) that do not have hatch as an attribute. > Yes, it seems that hatching is only supported in patches. You may workaround this by converting contours to multiple patches. See the attachment.

[Matplotlib-users] Plotting basemap on top of other data

2011-12-09 Thread Laat de, Jos (KNMI)
plot Basemap coastlines. However, the Basemap appears to have a non-transparent background, which overplots all bitmap data if I plot the Bitmap data first. I had hoped that there would be some transparency setting in Basemap, but alas. (ps. Keep in mind that I do not want to use some contour fi

Re: [Matplotlib-users] logairthmic contour plot

2012-06-14 Thread Benjamin Root
On Thursday, June 14, 2012, Daπid wrote: > First, this is another topic, so please, change the subject of the > message so it doesn't get messed up with others (and possible help > lost in the process). > > Now, you are indeed plotting one dot at the time and generating a > label for it. If you do

[Matplotlib-users] any way of having something like pcolorfast results with log scale ?

2012-06-25 Thread julien tayon
combining those 2 is possible : http://matplotlib.sourceforge.net/examples/mplot3d/contourf3d_demo2.html + log scale for y. I guess I could improve the result by using logscale on Z and colormap (http://stackoverflow.com/questions/5748076/python-matplotlib-contour-plot-logarithmic-color-scale) Since

Re: [Matplotlib-users] Bug in colorbar()

2012-07-29 Thread Eric Firing
rf(X,Y,Z, 100, cmap=matplotlib.cm.jet, norm = norm) > > it has the desired effect. > > Let me know if this is correct or I'm missing something here. > > Cheers, > Jeff You are correct. Contour and contourf are respecting vmin, vmax that have been set in the norm only if both

[Matplotlib-users] griddata fails

2013-01-09 Thread Shahar Shani-Kadmiel
Hi, I'm trying to contour some data that I have and the griddata line fails. I tried running it on some synthetically generated data and I get the same IndexError. Any Ideas? Here is the example with the synthetic data: x = y = arange(-10,10,0.01) z = x**2+y**3 xi = yi = linspace(

[Matplotlib-users] Basemap contourf question

2010-07-14 Thread Steve McFarlin
, name = 'theColorMap', N = len(colorList)) ... m.contourf(x,y,z,cmap=cmap, levels=levels, extend='both') If the levels array is continuous then it works as expected. With the above settings I get unexpected results, which includes 'ghost contour lines'. The data

Re: [Matplotlib-users] Boundary edges of a set of points

2011-04-29 Thread Ian Thomas
This sounds like a very sensible approach and is quick and easy to try out using tricontour/tricontourf. You may have to use a very small positive value for the contour level rather then zero to get what you want. > Is it clear what I am trying to do? If so, do you think the Delaunay > tria

[Matplotlib-users] Plotting 2D contourf in Axes3D X-Z plane instead of X-Y plane

2011-08-30 Thread Katie Boyle
Hi All, I have a 2D grid comprised of 100 nodes in X, 300 nodes in Z, and a single node in Y. I have a scalar value defined at each node point. I want to display this planar grid in 3D by first rendering a contour plot (no problems there) and then rotating it such that it plots as a vertical

[Matplotlib-users] animating surfaces

2007-01-12 Thread Matthew Koichi Grimes
s some unpleasant screen flicker. What's the Right Way to replot a changing surface+contour plot? Thanks, -- Matt - Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and y

Re: [Matplotlib-users] Transparent plot symbols

2008-04-15 Thread Eric Firing
Paul Smith wrote: > Hi, > I can't find a way to plot marker symbols that have a transparent face > colour, > so I can see the contour plot that's under them. Setting alpha affects the > edge colour as well. > Any suggestions? Paul, If you want the symbol faces

Re: [Matplotlib-users] Plotting in West Longitude

2006-07-29 Thread Jeff Whitaker
s and political boundaries. m = Basemap(llcrnrlon=0.,llcrnrlat=-90,urcrnrlon=360.,urcrnrlat=90.,resolution=None,projection='cyl') # use plot, contour, imshow, pcolor .. methods to plot the data here # draw parallels delat = 30. circles = arange(0.,90.+delat,delat).tolist()+

Re: [Matplotlib-users] plot x y value(x,y)

2006-10-13 Thread Louis Pecora
Hope this clarifies matters. > > Best regards, > Hanno > > Got it. Yes, sounds like you want a "3D" scatter plot. v (at some "height) over the surface of x,y points. There is a contour in matplotlib, but I don't think it will do what you want. I will go back

Re: [Matplotlib-users] Get contourf image as array

2014-10-16 Thread Benjamin Root
ll look in to using savefig and getting the data out. > > -Dave > > On 10/15/14, 12:42 PM, Joy merwin monteiro wrote: > > pardon the query if it seems dumb, but why don't you do a savefig() > > after plotting the data and then convert it to any format you like? > > &g

Re: [Matplotlib-users] Get contourf image as array

2014-10-16 Thread David Hoese
. > > -Dave > > On 10/15/14, 12:42 PM, Joy merwin monteiro wrote: > > pardon the query if it seems dumb, but why don't you do a savefig() > > after plotting the data and then convert it to any format you like? > > > > alternatively, contour() and c

[Matplotlib-users] Upgraded to 1.1.0, now only line graphs work!

2011-11-12 Thread John Ladasky
to be working all right, but images and contour graphs generate errors, and fail to draw. My procedure: I deleted every last old matplotlib-related file from my hard disk,from both my Python dist-packages directory and from my home directory. I got my build dependencies up to date, and

Re: [Matplotlib-users] Is there a 3D version of the quiver plot?

2013-03-07 Thread Brickle Macho
On 8/03/13 8:37 AM, Damon McDougall wrote: > Correct me if I'm wrong, but would a 2D quiver plot on top of a > contour plot work? What spaces does the surface map to/from? If your > surface can be expressed as a function f:R^2 -> R then it's equivalent > to look at it

Re: [Matplotlib-users] Smooth contourplots

2010-09-07 Thread Francesco Montesano
Dear Joe, finally I had time to come back to my python scritp for the contour plots. You're code works very nicelly and does exactly what I need. Thank you for the help Francesco 2010/7/26 Joe Kington : > It sounds like you're wanting a gaussian kernel density estimate (KDE) (not

Re: [Matplotlib-users] How to draw a region of interest

2006-08-07 Thread Charlie Moad
with a color > - make it work with layers > - add methods that return the pixel region or the contour coordinates > - make a nice class > > If anybody has made such a widget I would love to see the code, I hate > reinventing the wheel. > > If there is not such an e

[Matplotlib-users] Matplotlib Boa constructor plug-in

2006-10-29 Thread khromushin
x27;) self.igorPlotCanvas1.axes.set_title('Test imshow with colorbar') self.igorPlotCanvas2.imshowwithcontour(Z,extent=(-5,5,-5,5),origin='lower') self.igorPlotCanvas3.contourf(Z,extent=(-5,5,-5,5),origin='lower') self.igorPlotCanvas4.contour(Z,extent=(-5,5,-5,5),

Re: [Matplotlib-users] How can I put a white area in the middle of colorbar showing the masked data?

2014-03-01 Thread Eric Firing
colormaps_reference.html) and a norm with symmetric limits (vmin and vmax; you can let them be set automatically after you specify your symmetric set of contour boundaries appropriately) then it will be done for you. e.g., z = 10 * np.random.randn(20, 30) clevs = [-10, -5, -2, -1, 1, 2, 5, 1

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

2014-06-19 Thread Slavin, Jonathan
what I need not just put a line in the > contour. > I want to pick value along the red line, so which the data that placed on > the red line. > Then I will plot it in the other type of plot. > -- Jonathan D. Sl

Re: [Matplotlib-users] [matplotlib-devel] Development issue: Assign labels to colorbar extensions

2014-11-16 Thread Eric Firing
o, how can I do it It looks like you might be able to achieve what you want *without* using extensions, by using a custom colormap and/or norm. You would extend the actual contour levels to include the full range you want "ticked and labeled", but you would use the colormap and/or norm

Re: [Matplotlib-users] contourf map with values

2015-03-01 Thread Benjamin Root
easier: https://github.com/matplotlib/matplotlib/pull/4063 Cheers! Ben Root On Sun, Mar 1, 2015 at 10:53 AM, Sappy85 wrote: > Hallo, > > i have an important question. Is it possible with matplotlib function > "contourf()" to plot the values of the contour-data? Here i

Re: [Matplotlib-users] How to visualize a, b results of x, y variables

2015-07-08 Thread Sterling Smith
nt values. > There is a single optimal pair of a,b values and I'd like to figure out a way > to illustrate the data to show the relationship between each x,y pair and how > close each a,b pair is to the ideal. > I'm thinking about a dual surface/contour plot with 2 different z-

Re: [Matplotlib-users] Contouring on triangular grids

2009-09-18 Thread Christopher Barker
Andrew Straw wrote: > Thanks for this. Yes, indeed. It looks like nice stuff! I do encourage you to keep up the good work on this (the only thing I notice is the need for some more docs). I also encourage you to keep the contour generating code separate from anything matplotlib specific

Re: [Matplotlib-users] conourf() subplots with a single colorbar

2010-01-28 Thread Eric Firing
Sharaf Al-Sharif wrote: > Hi, > I'm trying to make a figure with a column of contourf() subplots using > matplotlib.pyplot. The contour plots have the same levels and I only > need one color bar. The problem is that I'm not sure how to place the > color bar in the figu

Re: [Matplotlib-users] Is there a "transparent" color, for overlaying contouf regions?

2010-02-01 Thread Eric Firing
Sourav K. Mandal wrote: > Hello, > > (This is a different question for the same project that led me to file a > bug about alpha blending in "contour" .) > > I want to overlay a number of exclusion regions in a 2D parameter scan. > I generate each region wi

Re: [Matplotlib-users] manual placement of a colorbar

2010-04-01 Thread Mathew Yeates
This doesn't work for what I'm doing. Unless I call "contour" or something similar, this will fail. I am only using m.plot and this doesn't set things up properly to call "colorbar". On Thu, Apr 1, 2010 at 12:40 PM, Jeff Whitaker wrote: > On 4/1/10

Re: [Matplotlib-users] setting zorder for basemap.imshow(); overlay on continents

2010-05-24 Thread P. R.M.
trying to create a precipitation contour plot using imshow() and basemap. Id like to draw the imshow() plot so that it overlays the filled continents, yet NOT the continental outlines. unfortunately, it appears that imshow()'s graphics are always drawn before everything else, so its 'zorder&

Re: [Matplotlib-users] Plotting grid data

2008-12-09 Thread Mauro Cavalcanti
previous post): "File "/usr/lib/python2.5/site-packages/matplotlib/axes.py", line 6091, in pcolormesh C = ma.ravel(C[0:Ny-1, 0:Nx-1]) # data point in each cell is value at IndexError: too many indices" > using contourf: > m.contourf(x,y,dat,clevs) Not tried because c

Re: [Matplotlib-users] Plotting grid data

2008-12-09 Thread Jeff Whitaker
in each cell is value at > IndexError: too many indices" > > >> using contourf: >> m.contourf(x,y,dat,clevs) >> > > Not tried because contour maps are not exactly what I need. > > >> using imshow: >> m.imshow(dat) >>

[Matplotlib-users] Two bugs in quiver?

2009-01-19 Thread George Nurser
nate(map(atleast_1d,tup),1) ValueError: array dimensions must agree except for d_0 2. Masking is not working properly with quiver, while it works fine with contour -- see the attached quivtest.png quiver.py: import numpy as np import numpy.ma as ma import matplotlib matplotlib.use('Agg')

Re: [Matplotlib-users] FW: basemap.contourf, colormap, extend='none', & levels array question

2009-03-15 Thread Eric Firing
t; > but I still got a plot with the '0.0' (land) areas plotted as > 'white'/missing?. > > Does it matter that the output I provided from the "Z.mask" command showed > all 'false' for the mask array? All this is strange again. I did

Re: [Matplotlib-users] logarithmic scale of colorbar with ticks and custom labels

2009-05-07 Thread Jae-Joon Lee
http://matplotlib.sourceforge.net/api/figure_api.html?highlight=colorbar#matplotlib.figure.Figure.colorbar cbar = colorbar(ticks=lev, format = l_f) -JJ On Wed, May 6, 2009 at 3:28 PM, Sebastian Pająk wrote: > Hello > > I have a contour plot with specified number of levels (isolines)

Re: [Matplotlib-users] logarithmic scale of colorbar with ticks and custom labels

2009-05-07 Thread Sebastian Pająk
n Wed, May 6, 2009 at 3:28 PM, Sebastian Pająk wrote: >> Hello >> >> I have a contour plot with specified number of levels (isolines): >> >> lev = array([2,3,5,7,10,13,17,21,26,32,42,62,80,100,120,140,180]) >> >> to have a log "z" axis I put: >> >&

Re: [Matplotlib-users] pcolor getting slow

2009-05-27 Thread Eric Firing
jinbo wang wrote: > Hi dear users, >Recently I found pcolor took tremendously longer to draw a figure > than contour or imshow. I am wondering if anyone had the same > experience, or anyone knows why? Thank you very much! Yes, pcolor is inherently very slow, but flexible. Im

Re: [Matplotlib-users] New contourf() drawing polygon boundaries for some reason?

2009-06-12 Thread Michael Droettboom
l > line crossing from each contour boundary to the next. I'm guessing > that these are the edges of the filled polygons which are getting > drawn. This behavior doesn't seem to be consistent with the > contourf() documentation and when I run code in griddata_demo.py it > d

Re: [Matplotlib-users] Plotting basemap on top of other data

2011-12-09 Thread Benjamin Root
etting in Basemap, but alas. > > > > (ps. Keep in mind that I do not want to use some contour filling routine for plotting the satellite data. I want to retain the original N x N pixels and image size) What commands are you using to plot the data? drawcoastlines() should only draw lines.

Re: [Matplotlib-users] Alpha keyword not working with contourf

2012-02-11 Thread Eric Firing
On 02/11/2012 07:40 AM, Alexa Villaume wrote: > Hi All, > > I'm just getting started with matplotlib. I'm trying to make a contour > plot using contourf and have the different paths colored and semi > transparent but the alpha keyword doesn't seem to do anything. I g

[Matplotlib-users] Labeling Contours

2012-02-15 Thread Alexa Villaume
Hi Everybody, I'm trying to label the contours of my contour plot following this example - http://matplotlib.sourceforge.net/examples/pylab_examples/contour_label_demo.html My actual code looks like this - import matplotlib matplotlib.use('PDF') from pylab import * imp

Re: [Matplotlib-users] griddata is not working after update to Python 2.7

2012-05-30 Thread Umut Yildiz
a simple way to do contour plotting on a simple 3 column file (x, y, z) where I gave a link to the table file in my previous email? Thanks a lot Umut > First, if you were importing griddata before like that, that it is quite > likely that it was some other module that was installed i

Re: [Matplotlib-users] Need to plot z at given x, y...contour? or something!

2012-09-14 Thread Eric Firing
On 2012/09/14 10:15 AM, Benjamin Root wrote: > > > On Fri, Sep 14, 2012 at 3:50 PM, Eric Firing > wrote: > > On 2012/09/14 9:00 AM, Benjamin Root wrote: > > tricontourf() might be more what you are looking for. Another > > possibility is pcolor() (note tha

Re: [Matplotlib-users] depth longitude plot

2013-03-04 Thread Sudheer Joseph
so is >it possible to specify the levels? >In [23]: plt.pcolormesh?? did not give much help > >with best regards, >Sudheer You can overlay contours on the pcolormesh image by simply using the plt.contour() function after the pcolormesh() call.  It allows you to control which leve

[Matplotlib-users] basemap and contouring

2010-09-13 Thread mdekauwe
Hi, If I set up a random example and plot it as a contour it seems to work fine...e.g. import matplotlb.pyplot as plt import numpy as np data2 = np.random.sample((17,16)) x = np.linspace(-1.74, -1.32, 16) y = np.linspace(15.15, 15.61, 17) X, Y = np.meshgrid(x, y) plt.contour(X, Y, data2

[Matplotlib-users] Basemap: High resolution output & cutout marks on contours

2010-10-04 Thread nickj
Hello all, I'm playing with Matplotlib & Basemap for the first time, and attempting to render data from the NOAA GFS models. With joy I finally got something on screen, however I was wondering what I might be able to do, to better improve the contour rendering of the final map.

Re: [Matplotlib-users] small patch to enable formatters for contour line labels

2011-02-21 Thread Daniel Hyams
Thanks Eric! On Sun, Feb 20, 2011 at 9:02 PM, Eric Firing wrote: > On 02/20/2011 06:17 AM, Daniel Hyams wrote: >> >> The function "clabel" does not allow the use of formatters for the >> label; this small patch enables their use, so that one can pass in any >> subclass of ticker.Formatter in the

[Matplotlib-users] Irregularly sized data without interpolation

2007-05-31 Thread Matthew Turk
lities of matplotlib -- specifically, I'm very excited about being able to plot this data, and then overplot contour or quiver plots (which I have done with my data using the delaunay method.) Any ideas? Thanks! -Matt - This SF.

[Matplotlib-users] Basemap projection issue

2007-10-11 Thread Adam Mercer
X, Y = map(x, y) map.contourf(X, Y, values) I get the following error: WARNING: x coordinate not montonically increasing - contour plot may not be what you expect. If it looks odd, your can either adjust the map projection region to be consistent with your data, or (if your data is on a glo

Re: [Matplotlib-users] Clipping a plot inside a polygon

2013-09-02 Thread Alex Goodman
le. I think it has the potential to be a good basemap replacement thanks to the more robust shapefile support (which you have very elegantly shown), and I hope the development goes well. Thanks, Alex On Mon, Sep 2, 2013 at 2:33 AM, Phil Elson wrote: > Great question. The contour set itself do

Re: [Matplotlib-users] Can't plot NCEP reanalysis data

2014-03-05 Thread Signell, Richard
>>> f = nc.Dataset('D:/data/omega.mon.mean.nc','r') >>> omg = f.variables['omega'][0] >>> lon = f.variables['lon'][:] >>> lat = f.variables['lat'][:] >>> times = f.variables['time'][:] >>>

Re: [Matplotlib-users] New contourf() drawing polygon boundaries for some reason?

2009-06-14 Thread Michael Droettboom
setup. It looks as if for some reason the vertices of the filled polygons are being calculated differently from different sides of the same contour, leading to overlap in some places, and gaps in others. You can download the PDF version (in which the exact geometry is much clearer). from: http://

Re: [Matplotlib-users] Upgraded to 1.1.0, now only line graphs work!

2011-11-12 Thread Benjamin Root
red to build successfully, but I still have problems. > > Line graphs appear to be working all right, but images and contour > graphs generate errors, and fail to draw. > > > My procedure: > > I deleted every last old matplotlib-related file from my hard disk,from > bot

Re: [Matplotlib-users] Clipping Contours

2012-10-16 Thread T J
need to clip >> everything outside the triangle, as only points within the triangle >> correspond to actual distributions. >> >> Is there a more direct way to calculate contours on a restricted set? >> >> Thanks. > > The contour functions support masked regi

Re: [Matplotlib-users] Is there a 3D version of the quiver plot?

2013-03-07 Thread Nelle Varoquaux
On 8 March 2013 03:19, Brickle Macho wrote: > On 8/03/13 8:37 AM, Damon McDougall wrote: > > Correct me if I'm wrong, but would a 2D quiver plot on top of a > > contour plot work? What spaces does the surface map to/from? If your > > surface can be expressed as a fun

Re: [Matplotlib-users] Basemap contourf question

2010-07-14 Thread Steve McFarlin
> Turning off antialiasing did not solve the 'ghost lines'. I will play around > with some of the arguments. It looks to me as if contour is being called with > a line width of 1 and a color of white. Setting these line width to 0 did not > make a difference. > > > T

[Matplotlib-users] ANN: matplotlib-0.87.4 (bugfix release for enthon)

2006-07-11 Thread Charlie Moad
plotted if rcParams['axes.hold'] was False. - MAS 2006-06-22 Added support for numerix 2-D arrays as alternatives to a sequence of (x,y) tuples for specifying paths in collections, quiver, contour, pcolor, transforms. Fixed contour bug involving se

Re: [Matplotlib-users] Plotting large file (NetCDF)

2014-09-09 Thread Benjamin Root
;> > What might be happening is that you are keeping around too many numpy >> arrays in memory than you actually need. Take advantage of memmapping, >> which most netcdf tools provide by default. This keeps the data on disk >> rather than in RAM. Second, for very la

Re: [Matplotlib-users] Plotting large file (NetCDF)

2014-09-09 Thread Raffaele Quarta
> > >> > What might be happening is that you are keeping around too many numpy >> arrays in memory than you actually need. Take advantage of memmapping, >> which most netcdf tools provide by default. This keeps the data on disk >> rather than in RAM. Second,

Re: [Matplotlib-users] could I get rid of the contour of Antarctica by using Basemap?

2013-12-30 Thread Sterling Smith
Chao, I know nothing of the Basemap toolkit so I can't comment on the removal of continents, but presumably the text command you are using takes some keywords to set the properties of the bounding box. Try setting the background of the bounding box to white so that your words show up cleanly.

[Matplotlib-users] Plotting date as hh:mm in contourf from seconds

2014-02-06 Thread Mario Mech
np.array([[143., 143., 133., 143.], [172., 162., 122., 172.], [201., 241., 201., 201.]]) z = np.random.rand(3,4) fig = pyplot.figure() dnt = dates.num2date(dates.epoch2num(x[0])) ax2 = fig.add_axes([0.1,0.1,0.8,0.8]) c = ax2.contour(dnt,y[:,0],z) for coll in c.collec

[Matplotlib-users] Issue with relim and autoscale_view in 1.3.1

2014-03-04 Thread Stuart Mentzer
Hi, I'm seeing odd behavior with the relim() and autoscale_view() call sequence with matplotlib 1.3.1. In some cases I am ending up with axis ranges of [-0.05,0.05] instead of the actual data ranges. This happens with scatter plots and sometimes with contour

Re: [Matplotlib-users] Set X,Y,and Z data for a pcolormesh

2014-04-03 Thread Benjamin Root
#x27;s normal vector, and the "offset" argument to set the location of the slice. In this particular example, the three contourf()'s were purposely placed on the edges of the axes, but they can be placed anywhere you want them to be. You will need to supply contourf() with the appropria

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

2014-06-19 Thread Oliver
ib.org/examples/event_handling/pick_event_demo.html 2014-06-19 2:56 GMT+02:00 dydy2014 : > Thank you Paul for your comment, but what I need not just put a line in the > contour. > I want to pick value along the red line, so which the data that placed on > the red line. >

[Matplotlib-users] Basemap shiftgrid

2014-08-27 Thread mmc
Hi All, I am having problems plotting data in Basemap. I have tried some of the different projections such as Robinson and Equidistant Cylindrical, however kept running into the error WARNING: x coordinate not monotonically increasing - contour plot may not be what you expect. If it looks odd

[Matplotlib-users] How to plot saved plot data in a new figure?

2009-09-18 Thread Michael McNeil Forbes
Hi, Is there a standard way to compute first and then plot something later? For example, I would like to generate a fine contour plot, then use it as a background later. x = np.linspace(-1,1,1000) X,Y = np.meshgrid(x,x) Z = ((X*X + Y*Y) - 0.5)**2 + Y**2 contours = plt.contour(X,Y,Z,100

[Matplotlib-users] Problems generating postscript!

2010-01-02 Thread Eric Emsellem
Hi I am having reccurrent problem generating postscript files using savefig. I am basically generating a figure with lots of small thumbnail images (loaded with mpl pcolormesh and contour) and some overimposed text. When I do: savefig("myfig.eps") it takes quite a while, and makes

Re: [Matplotlib-users] Contour Plotting of Varied Data on a Shape

2010-03-11 Thread Chris Barker
Robert Kern wrote: >> the triangulation. Yes, it would use the existing delaunay code by >> default, and hopefully optionally use the not-as-good-a-license code the >> Robert Kern put in SciPy. > > I did what now? I thought you'd put a wrapper of a delaunay code that is GPL'd or something (not B

[Matplotlib-users] Setting boundaries for a colorbar

2010-04-14 Thread Andreas Hilboll
8<--- So I have data ranging from 0 up to say 675. I want to create a contour plot, but the colorbar should only go up to 400, and all values higher than that should be shown in the color of the maximum value 400, which is working fine. However, the colorbar does not go from 0 to 400, but r

Re: [Matplotlib-users] coordinate transformation: Basemap vs. Proj

2010-05-04 Thread Jeff Whitaker
> (meters). I want to contour the data with Basemap. The data are in a > sinusoidal projection, but the coordinates do not correspond to what > Basemap seems to expect. > > The code below illustrates the problem. Proj translates the upper > left to lat/lon correctly (-92.32

Re: [Matplotlib-users] Generating an isosurface (mesh) out of a 3d array [SEC=UNCLASSIFIED]

2008-08-21 Thread Ryan May
meshcube of the x oridnate > Y:... > Z:... > V: array/list where len(V.shape)=3 > level: float, level of isosurface > > I can kind of envisage a way it could be done by generating contours on > constant Z slices of the cube and then searching for the closest vertices of > the con

<    5   6   7   8   9   10   11   12   13   >