You can subscribe to this list here.
| 2003 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(3) |
Jun
|
Jul
|
Aug
(12) |
Sep
(12) |
Oct
(56) |
Nov
(65) |
Dec
(37) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2004 |
Jan
(59) |
Feb
(78) |
Mar
(153) |
Apr
(205) |
May
(184) |
Jun
(123) |
Jul
(171) |
Aug
(156) |
Sep
(190) |
Oct
(120) |
Nov
(154) |
Dec
(223) |
| 2005 |
Jan
(184) |
Feb
(267) |
Mar
(214) |
Apr
(286) |
May
(320) |
Jun
(299) |
Jul
(348) |
Aug
(283) |
Sep
(355) |
Oct
(293) |
Nov
(232) |
Dec
(203) |
| 2006 |
Jan
(352) |
Feb
(358) |
Mar
(403) |
Apr
(313) |
May
(165) |
Jun
(281) |
Jul
(316) |
Aug
(228) |
Sep
(279) |
Oct
(243) |
Nov
(315) |
Dec
(345) |
| 2007 |
Jan
(260) |
Feb
(323) |
Mar
(340) |
Apr
(319) |
May
(290) |
Jun
(296) |
Jul
(221) |
Aug
(292) |
Sep
(242) |
Oct
(248) |
Nov
(242) |
Dec
(332) |
| 2008 |
Jan
(312) |
Feb
(359) |
Mar
(454) |
Apr
(287) |
May
(340) |
Jun
(450) |
Jul
(403) |
Aug
(324) |
Sep
(349) |
Oct
(385) |
Nov
(363) |
Dec
(437) |
| 2009 |
Jan
(500) |
Feb
(301) |
Mar
(409) |
Apr
(486) |
May
(545) |
Jun
(391) |
Jul
(518) |
Aug
(497) |
Sep
(492) |
Oct
(429) |
Nov
(357) |
Dec
(310) |
| 2010 |
Jan
(371) |
Feb
(657) |
Mar
(519) |
Apr
(432) |
May
(312) |
Jun
(416) |
Jul
(477) |
Aug
(386) |
Sep
(419) |
Oct
(435) |
Nov
(320) |
Dec
(202) |
| 2011 |
Jan
(321) |
Feb
(413) |
Mar
(299) |
Apr
(215) |
May
(284) |
Jun
(203) |
Jul
(207) |
Aug
(314) |
Sep
(321) |
Oct
(259) |
Nov
(347) |
Dec
(209) |
| 2012 |
Jan
(322) |
Feb
(414) |
Mar
(377) |
Apr
(179) |
May
(173) |
Jun
(234) |
Jul
(295) |
Aug
(239) |
Sep
(276) |
Oct
(355) |
Nov
(144) |
Dec
(108) |
| 2013 |
Jan
(170) |
Feb
(89) |
Mar
(204) |
Apr
(133) |
May
(142) |
Jun
(89) |
Jul
(160) |
Aug
(180) |
Sep
(69) |
Oct
(136) |
Nov
(83) |
Dec
(32) |
| 2014 |
Jan
(71) |
Feb
(90) |
Mar
(161) |
Apr
(117) |
May
(78) |
Jun
(94) |
Jul
(60) |
Aug
(83) |
Sep
(102) |
Oct
(132) |
Nov
(154) |
Dec
(96) |
| 2015 |
Jan
(45) |
Feb
(138) |
Mar
(176) |
Apr
(132) |
May
(119) |
Jun
(124) |
Jul
(77) |
Aug
(31) |
Sep
(34) |
Oct
(22) |
Nov
(23) |
Dec
(9) |
| 2016 |
Jan
(26) |
Feb
(17) |
Mar
(10) |
Apr
(8) |
May
(4) |
Jun
(8) |
Jul
(6) |
Aug
(5) |
Sep
(9) |
Oct
(4) |
Nov
|
Dec
|
| 2017 |
Jan
(5) |
Feb
(7) |
Mar
(1) |
Apr
(5) |
May
|
Jun
(3) |
Jul
(6) |
Aug
(1) |
Sep
|
Oct
(2) |
Nov
(1) |
Dec
|
| 2018 |
Jan
|
Feb
|
Mar
|
Apr
(1) |
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2020 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(1) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2025 |
Jan
(1) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
|
From: Qian P. <qia...@gm...> - 2012-08-07 17:58:35
|
Hi,
In matplotlib, is there a way to check whether a window related to a
figure has been closed by user?
x=[1,2,3]
fig = plt.figure()
fig.show()
plt.plot(x,x)
plt.draw()
later in the code, I want to make draw some other line, possibly on the
same figure. I can switch to the preivious figure by
plt.figure(fig.number)
but it seems that even if fig has been closed by the user, this will still
work because the information stored in fig is still accessible. Then, this
fig.number would actually point some other picture.
So, is there any state information in fig that would tell whether the
window of fig has been closed by user?
Thanks
Qian
|
|
From: darkside <in....@gm...> - 2012-08-07 10:48:06
|
Hi everyone,
I'm trying to make a zoom of a single plot. The problem is that the zoomed
axes yticks overlap with the yaxes so I tried to use the bbox_to_anchor
option in the zoom:
axins = zoomed_inset_axes(ax,
3,bbox_to_anchor=(0.4,0.4),bbox_transform=ax.transAxes, loc=2)
with different (x,y) parameters, but it's not working.
I also tried to move the figure by hand:
box = axins.get_position()
print box
axins.set_position([box.x0+0.5, box.y0,box.width, box.height])
box = axins.get_position()
print box
and I see that box numbers changing, but not in the plot.
Can anyone guess what I am doing wrong?
Thank you all!
PS: The full code for this plot is:
def plotvsdata(data,z,dl,nu):
"""
Plot of z vs. Dl for different nu values
"""
fig = p.figure(figsize=(12,8))
ax = p.subplot(111)
# FLRW light distance
ax.plot(z[0],Dl_lflrw(z[0],0.3,0.7),'k--',label=r'Dl $\Lambda$FLRW')
# mean data values
ax.plot(data.redshift,data.distance,'r.',label='SCP data')
p.xlabel('z',fontsize=18)
p.ylabel('Luminosity distance',fontsize=18)
p.grid(True)
#axins = zoomed_inset_axes(ax,3,loc=2,bbox_to_anchor=(0.5,0.5))
#axins = zoomed_inset_axes(ax,3,loc=2,bbox_to_anchor=(0.4,0.4)
,bbox_transform=ax.transAxes)
axins = zoomed_inset_axes(ax,
3,bbox_to_anchor=(1,1),bbox_transform=ax.transAxes, loc=2)
#box = axins.get_position()
#print box
#axins.set_position([box.x0+0.5, box.y0,box.width, box.height])
#box = axins.get_position()
#print box
# Kantowski equation
for i in range(len(z)):
ax.plot(z[i],dl[i],label=r'$\nu={0:1.2f}$'.format(nu[i]))
axins.plot(z[i],dl[i])
axins.plot(data.redshift,data.distance,'r.', label='SCP data')
#box = ax.get_position()
#ax.set_position([box.x0,box.y0,box.width*0.8,box.height])
ax.legend(loc=2,bbox_to_anchor=(1,1))
x,y = (0.86,1.3)
x2,y2 = (1,1.7)
axins.set_xlim(x,x2)
axins.set_ylim(y,y2)
axins.tick_params(axis='both',labelsize=12)
axins.xaxis.set_major_locator(MaxNLocator(2))
axins.yaxis.set_major_locator(MaxNLocator(3))
#box = axins.get_position()
#print box
#axins.set_position([box.x0+0.5, box.y0,box.width, box.height])
#box = axins.get_position()
#print box
# draw a bbox of the region to zoom and connecting lines between it
# and the zoomed box.
mark_inset(ax,axins,loc1=1,loc2=3, fc="none", ec="0.5")
#p.xticks(visible=False)
#p.yticks(visible=False)
p.draw()
p.show()
|
|
From: Mark B. <ma...@gm...> - 2012-08-07 10:42:04
|
I tried a few things and found out that doing a pause works.
So why does a pause work, but a draw() or show() does not?
This all on Windows using the standard PythonXY installation.
Here is the code that works (testimage.py):
from pylab import *
c = ones((10,20))
ax = imshow(c)
pause(0.01)
print ax.get_axes().get_position()
Running from IPython:
run testimage
Bbox(array([[ 0.125 , 0.24166667],
[ 0.9 , 0.75833333]]))
On Wed, Aug 1, 2012 at 8:56 PM, Stan West <sta...@nr...> wrote:
> **
>
> *From:* Mark Bakker [mailto:ma...@gm...]
> *Sent:* Monday, July 30, 2012 05:54
>
> Hello List,
>
> I am trying to determine the position of the axes after an imshow and am
> having problems.
> I get a different answer on my Mac (the correct answer) than Windows (the
> wrong answer).
>
> [...]
>
> Any thoughts? When I type the commands in at the IPython prompt it works
> most of the time (on Windows), but it never works when running the file.
> What in the world could be different?
>
> mp version 1.1.0 on both systems.
>
> Are you using the same backend on both systems?
>
> Perhaps when you run the script within IPython on your Windows system, the
> show() call is not triggering a draw. You can force drawing by calling
> draw() before show(). I hope that helps.
>
|
|
From: Scott S. <sco...@gm...> - 2012-08-07 06:50:17
|
On 7 August 2012 03:10, Jeff Whitaker <js...@fa...> wrote: > Available for download at > https://sourceforge.net/projects/matplotlib/files/matplotlib-toolkits/basemap-1.0.5/ Just a note to anyone experiencing problems building against GEOS 3.3.3 installed from the ubuntu-gis-unstable PPA on Ubuntu. The naming convention for the GEOS shared library has changed and I had to apply the patch below as a workaround: diff --git a/setup.py b/setup.py index 216ddf6..dc6d916 100644 --- a/setup.py +++ b/setup.py @@ -82,7 +82,7 @@ else: library_dirs=geos_library_dirs, runtime_library_dirs=geos_library_dirs, include_dirs=geos_include_dirs, - libraries=['geos_c','geos'])) + libraries=['geos_c','geos-3.3.3'])) # Specify all the required mpl data # create pyproj binary datum shift grid files. Apparently this is an acceptable practice on Debian systems (http://www.debian.org/doc/debian-policy/ch-sharedlibs.html#s-shlibs), but no time to dream up a more robust fix right now.. Cheers, Scott |
|
From: Jeff W. <js...@fa...> - 2012-08-07 01:10:21
|
Available for download at https://sourceforge.net/projects/matplotlib/files/matplotlib-toolkits/basemap-1.0.5/ Thanks to Christoph Gohlke for making windows installers. Highlights: - new 'latlon' keyword for contour,contourf,pcolor,pcolormesh,quiver,barb methods that automatically converts x, y from longitude/latitude to map projection coordinates, and for global projections shifts the data longitudinally to fit in map projection region (see shiftdata.py example). - fixed a serious bug that caused a bogus mask to be applied to the data when the contour method was called (did not affect contourf). full Changelog: version 1.0.5 (git tag v1.0.5rel) -------------------------------- * fix bug triggered when drawlsmask method called more than once. * fix error in contour method that caused a bogus mask to be applied to the data (issue 58). * fix further corner cases with splitting of parallels that cross the dateline (issue 40). * add latlon keyword to plotting methods. If latlon=True, x and y values are assumed to longitudes and latitudes in degrees. The data and longitudes are shifted to the map projection region (for cylindrical and pseudo-cylindrical projections) using the shiftdata method, and lons/lats are converted to map projection coords. Default value is False. Addresses issue 54. New example shiftdata.py added to illustrate usage. * fix bluemarble and warpimage methods to account for change in orientation of arrays returned to matplotlib's pil_to_array (issue 51) * fix glitch with drawing meridians and filling coastline polygons with omerc projection that includes pole. Regards, Jeff |
|
From: Benjamin R. <ben...@ou...> - 2012-08-05 18:55:35
|
On Sunday, August 5, 2012, Nikolaus Rath wrote: > Benjamin Root <ben...@pu... <javascript:;>> > writes: > > On Sunday, August 5, 2012, Nikolaus Rath wrote: > > > >> Hello, > >> > >> The following code shows the plot right away as expected: > >> > >> # python > >> Python 2.7.3rc2 (default, Apr 22 2012, 22:30:17) > >> [GCC 4.6.3] on linux2 > >> Type "help", "copyright", "credits" or "license" for more information. > >> >>> import matplotlib > >> >>> matplotlib.__version__ > >> '1.1.1rc2' > >> >>> import matplotlib.pyplot as plt > >> >>> plt.interactive(True) > >> >>> plt.plot(range(10)) > >> [<matplotlib.lines.Line2D object at 0x2ce7790>] > >> > >> > >> This, however, opens a window but the graph never shows up: > >> > >> # python > >> Python 2.7.3rc2 (default, Apr 22 2012, 22:30:17) > >> [GCC 4.6.3] on linux2 > >> Type "help", "copyright", "credits" or "license" for more information. > >> >>> import matplotlib.pyplot as plt > >> >>> plt.interactive(True) > >> >>> fig = plt.figure() > >> >>> ax = fig.add_subplot(1,1,1) > >> >>> ax.plot(range(10)) > >> [<matplotlib.lines.Line2D object at 0x3055d90>] > >> >>> > >> > >> Does interactive mode only apply to the plot commands in pyplot? > >> > >> Is there a method I can call in this case to "refresh" the window and > >> show the plot? > >> > >> For seem reason, calling plt.axes() has the desired effect, but this is > >> probably a side effect that I really should not rely on, right? > > > > Correct, I think you want plt.draw(). > > Thanks, that works! But why is it necessary? Does interactive mode only > apply to direct pyplot.* commands? > > > Thanks, > > -Nikolaus Not quite. It is that the pyplot commands have a "draw_if_interactive" call as a final step. This way, matplotlib can defer drawing until it is really needed. This improves responsiveness. When in OO mode, the training wheels come off and the developer is responsible for issuing draw() calls when they need to. Cheers! Ben Root |
|
From: Nikolaus R. <Nik...@ra...> - 2012-08-05 16:32:59
|
Benjamin Root <ben...@pu...> writes: > On Sunday, August 5, 2012, Nikolaus Rath wrote: > >> Hello, >> >> The following code shows the plot right away as expected: >> >> # python >> Python 2.7.3rc2 (default, Apr 22 2012, 22:30:17) >> [GCC 4.6.3] on linux2 >> Type "help", "copyright", "credits" or "license" for more information. >> >>> import matplotlib >> >>> matplotlib.__version__ >> '1.1.1rc2' >> >>> import matplotlib.pyplot as plt >> >>> plt.interactive(True) >> >>> plt.plot(range(10)) >> [<matplotlib.lines.Line2D object at 0x2ce7790>] >> >> >> This, however, opens a window but the graph never shows up: >> >> # python >> Python 2.7.3rc2 (default, Apr 22 2012, 22:30:17) >> [GCC 4.6.3] on linux2 >> Type "help", "copyright", "credits" or "license" for more information. >> >>> import matplotlib.pyplot as plt >> >>> plt.interactive(True) >> >>> fig = plt.figure() >> >>> ax = fig.add_subplot(1,1,1) >> >>> ax.plot(range(10)) >> [<matplotlib.lines.Line2D object at 0x3055d90>] >> >>> >> >> Does interactive mode only apply to the plot commands in pyplot? >> >> Is there a method I can call in this case to "refresh" the window and >> show the plot? >> >> For seem reason, calling plt.axes() has the desired effect, but this is >> probably a side effect that I really should not rely on, right? > > Correct, I think you want plt.draw(). Thanks, that works! But why is it necessary? Does interactive mode only apply to direct pyplot.* commands? Thanks, -Nikolaus -- »Time flies like an arrow, fruit flies like a Banana.« PGP fingerprint: 5B93 61F8 4EA2 E279 ABF6 02CF A9AD B7F8 AE4E 425C |
|
From: Benjamin R. <ben...@ou...> - 2012-08-05 15:58:45
|
On Sunday, August 5, 2012, Nikolaus Rath wrote: > Hello, > > The following code shows the plot right away as expected: > > # python > Python 2.7.3rc2 (default, Apr 22 2012, 22:30:17) > [GCC 4.6.3] on linux2 > Type "help", "copyright", "credits" or "license" for more information. > >>> import matplotlib > >>> matplotlib.__version__ > '1.1.1rc2' > >>> import matplotlib.pyplot as plt > >>> plt.interactive(True) > >>> plt.plot(range(10)) > [<matplotlib.lines.Line2D object at 0x2ce7790>] > > > This, however, opens a window but the graph never shows up: > > # python > Python 2.7.3rc2 (default, Apr 22 2012, 22:30:17) > [GCC 4.6.3] on linux2 > Type "help", "copyright", "credits" or "license" for more information. > >>> import matplotlib.pyplot as plt > >>> plt.interactive(True) > >>> fig = plt.figure() > >>> ax = fig.add_subplot(1,1,1) > >>> ax.plot(range(10)) > [<matplotlib.lines.Line2D object at 0x3055d90>] > >>> > > Does interactive mode only apply to the plot commands in pyplot? > > Is there a method I can call in this case to "refresh" the window and > show the plot? > > For seem reason, calling plt.axes() has the desired effect, but this is > probably a side effect that I really should not rely on, right? > > > Thanks! > > -Nikolaus Correct, I think you want plt.draw(). Cheers! Ben Root |
|
From: Nikolaus R. <Nik...@ra...> - 2012-08-05 15:52:35
|
Hello, The following code shows the plot right away as expected: # python Python 2.7.3rc2 (default, Apr 22 2012, 22:30:17) [GCC 4.6.3] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>> import matplotlib >>> matplotlib.__version__ '1.1.1rc2' >>> import matplotlib.pyplot as plt >>> plt.interactive(True) >>> plt.plot(range(10)) [<matplotlib.lines.Line2D object at 0x2ce7790>] This, however, opens a window but the graph never shows up: # python Python 2.7.3rc2 (default, Apr 22 2012, 22:30:17) [GCC 4.6.3] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>> import matplotlib.pyplot as plt >>> plt.interactive(True) >>> fig = plt.figure() >>> ax = fig.add_subplot(1,1,1) >>> ax.plot(range(10)) [<matplotlib.lines.Line2D object at 0x3055d90>] >>> Does interactive mode only apply to the plot commands in pyplot? Is there a method I can call in this case to "refresh" the window and show the plot? For seem reason, calling plt.axes() has the desired effect, but this is probably a side effect that I really should not rely on, right? Thanks! -Nikolaus -- »Time flies like an arrow, fruit flies like a Banana.« PGP fingerprint: 5B93 61F8 4EA2 E279 ABF6 02CF A9AD B7F8 AE4E 425C |
|
From: Joshua K. <jjk...@gm...> - 2012-08-03 19:26:35
|
Hi all,
I am creating a GUI using wxPython and Matplotlib. In it, I am trying to
delete an axis in a figure and then adding another axis to the same figure.
In essence, I am attempting to dynamically update the figure. I am using
pylab.figure.
I am using the figure.delaxes function to delete the desired axes. That
works fine. I am then changing the geometry of the rest of the axes to
update the display. Afterwards, I am trying to append a new axes to the end
after updating the other axes (once again using change_geometry).
Pseudocode:
- delete the selected axis using figure.delaxes(axis)
- update the rest of the axes using change_geometry
- when it is time to add a new axis
-update the current axes using change_geometry
-add a subplot to the end
This approach works fine if the axes that was deleted was the axis on the
end (the last one). If the deleted axis was in the middle or beginning then
the figure.add_subplot(...) does not add an axis to the figure. Instead, it
returns the previous axis. So if there were two axes left when one axis in
the middle was deleted, ie. [axis1, axis2], figure.add_subplot would return
axis2 and so the axes list would still be [axis1, axis2]
This occurs both in the GUI and when run interactively via PyCrust.
Any thoughts on to why this would happen?
python 2.7
matplotlib version: 1.1.0
OS X 10.6.8
|
|
From: surfcast23 <sur...@gm...> - 2012-08-03 04:40:43
|
Gotcha ya working perfectly now thank you for the help! Benjamin Root-2 wrote: > > On Thursday, August 2, 2012, surfcast23 wrote: > >> >> Wouldn't >> >> X= np.ones((1, 45)) >> Y= np.zeros((32, 1)) >> >> change the existing values of the elements to ones and zeros? >> >> > I was just demonstrating what np.broadcast_arrays() does. Take your x and > y arrays and put them through this function and put the outputs into > plot_wireframe(). Ignore the ones() and zeros(). > > Ben Root > > ------------------------------------------------------------------------------ > Live Security Virtual Conference > Exclusive live event will cover all the ways today's security and > threat landscape has changed and how IT managers can respond. Discussions > will include endpoint security, mobile security and the latest in malware > threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > _______________________________________________ > Matplotlib-users mailing list > Mat...@li... > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > > -- View this message in context: http://old.nabble.com/Size-of-array-elements-when-using-Axes3D.plot_wireframe%28X%2C-Y%2C-Z%2C-*args%2C-**kwargs%29-tp34243823p34249265.html Sent from the matplotlib - users mailing list archive at Nabble.com. |
|
From: Benjamin R. <ben...@ou...> - 2012-08-03 04:28:15
|
On Friday, August 3, 2012, surfcast23 wrote: > > I tested it out and it does change all the values to ones and zeros. Is > there > a way to broadcast and keep the original values that were in the arrays? > Thanks for the help > > > Don't use ones() and zeros(). It was just a way to swtup a demonstration since I dont have your data. Use your data instead of my ones() and zeros(). Also, it would be more useful to post your latest version of your code that is causing problems so that we can double-check it, rather than guessing what the problem is. Cheers! Ben Root |
|
From: surfcast23 <sur...@gm...> - 2012-08-03 04:03:11
|
I tested it out and it does change all the values to ones and zeros. Is there a way to broadcast and keep the original values that were in the arrays? Thanks for the help Benjamin Root-2 wrote: > > On Thursday, August 2, 2012, surfcast23 wrote: > >> >> Okay thank you! The Matlab code I am basing this on takes arrays of >> different >> shapes with different sized elements ie >> x = 1 512 >> y = 101 1 >> and I guess automatically makes the the same shape. Can you point me in >> the >> direction of documentation that will explain how I can do this in Python? >> >> > Ok, I just double-checked the source for plot_wireframe(). It does not > perform any broadcasting (which I consider to be a bug). > > Until it is fixed, you will have to do the broadcasting yourself: > > X= np.ones((1, 45)) > Y= np.zeros((32, 1)) > x, y = np.broadcast_arrays(X, Y) > > Which produces x and y with the same shapes, and their values duplicated > in > the direction the array was "expanded". > > Pass those into plot_wireframe(). > > Ben Root > > ------------------------------------------------------------------------------ > Live Security Virtual Conference > Exclusive live event will cover all the ways today's security and > threat landscape has changed and how IT managers can respond. Discussions > will include endpoint security, mobile security and the latest in malware > threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > _______________________________________________ > Matplotlib-users mailing list > Mat...@li... > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > > -- View this message in context: http://old.nabble.com/Size-of-array-elements-when-using-Axes3D.plot_wireframe%28X%2C-Y%2C-Z%2C-*args%2C-**kwargs%29-tp34243823p34249203.html Sent from the matplotlib - users mailing list archive at Nabble.com. |
|
From: Benjamin R. <ben...@ou...> - 2012-08-03 03:54:08
|
On Thursday, August 2, 2012, surfcast23 wrote: > > Wouldn't > > X= np.ones((1, 45)) > Y= np.zeros((32, 1)) > > change the existing values of the elements to ones and zeros? > > I was just demonstrating what np.broadcast_arrays() does. Take your x and y arrays and put them through this function and put the outputs into plot_wireframe(). Ignore the ones() and zeros(). Ben Root |
|
From: surfcast23 <sur...@gm...> - 2012-08-03 03:50:09
|
sorry misssed this line "Which produces x and y with the same shapes, and their values duplicated in the direction the array was "expanded"." surfcast23 wrote: > > Wouldn't > > X= np.ones((1, 45)) > Y= np.zeros((32, 1)) > > change the existing values of the elements to ones and zeros? > > > Benjamin Root-2 wrote: >> >> On Thursday, August 2, 2012, surfcast23 wrote: >> >>> >>> Okay thank you! The Matlab code I am basing this on takes arrays of >>> different >>> shapes with different sized elements ie >>> x = 1 512 >>> y = 101 1 >>> and I guess automatically makes the the same shape. Can you point me in >>> the >>> direction of documentation that will explain how I can do this in >>> Python? >>> >>> >> Ok, I just double-checked the source for plot_wireframe(). It does not >> perform any broadcasting (which I consider to be a bug). >> >> Until it is fixed, you will have to do the broadcasting yourself: >> >> X= np.ones((1, 45)) >> Y= np.zeros((32, 1)) >> x, y = np.broadcast_arrays(X, Y) >> >> Which produces x and y with the same shapes, and their values duplicated >> in >> the direction the array was "expanded". >> >> Pass those into plot_wireframe(). >> >> Ben Root >> >> ------------------------------------------------------------------------------ >> Live Security Virtual Conference >> Exclusive live event will cover all the ways today's security and >> threat landscape has changed and how IT managers can respond. Discussions >> will include endpoint security, mobile security and the latest in malware >> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ >> _______________________________________________ >> Matplotlib-users mailing list >> Mat...@li... >> https://lists.sourceforge.net/lists/listinfo/matplotlib-users >> >> > > -- View this message in context: http://old.nabble.com/Size-of-array-elements-when-using-Axes3D.plot_wireframe%28X%2C-Y%2C-Z%2C-*args%2C-**kwargs%29-tp34243823p34249160.html Sent from the matplotlib - users mailing list archive at Nabble.com. |
|
From: surfcast23 <sur...@gm...> - 2012-08-03 03:45:42
|
Wouldn't X= np.ones((1, 45)) Y= np.zeros((32, 1)) change the existing values of the elements to ones and zeros? Benjamin Root-2 wrote: > > On Thursday, August 2, 2012, surfcast23 wrote: > >> >> Okay thank you! The Matlab code I am basing this on takes arrays of >> different >> shapes with different sized elements ie >> x = 1 512 >> y = 101 1 >> and I guess automatically makes the the same shape. Can you point me in >> the >> direction of documentation that will explain how I can do this in Python? >> >> > Ok, I just double-checked the source for plot_wireframe(). It does not > perform any broadcasting (which I consider to be a bug). > > Until it is fixed, you will have to do the broadcasting yourself: > > X= np.ones((1, 45)) > Y= np.zeros((32, 1)) > x, y = np.broadcast_arrays(X, Y) > > Which produces x and y with the same shapes, and their values duplicated > in > the direction the array was "expanded". > > Pass those into plot_wireframe(). > > Ben Root > > ------------------------------------------------------------------------------ > Live Security Virtual Conference > Exclusive live event will cover all the ways today's security and > threat landscape has changed and how IT managers can respond. Discussions > will include endpoint security, mobile security and the latest in malware > threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > _______________________________________________ > Matplotlib-users mailing list > Mat...@li... > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > > -- View this message in context: http://old.nabble.com/Size-of-array-elements-when-using-Axes3D.plot_wireframe%28X%2C-Y%2C-Z%2C-*args%2C-**kwargs%29-tp34243823p34249151.html Sent from the matplotlib - users mailing list archive at Nabble.com. |
|
From: Benjamin R. <ben...@ou...> - 2012-08-03 02:32:51
|
On Thursday, August 2, 2012, surfcast23 wrote: > > Okay thank you! The Matlab code I am basing this on takes arrays of > different > shapes with different sized elements ie > x = 1 512 > y = 101 1 > and I guess automatically makes the the same shape. Can you point me in the > direction of documentation that will explain how I can do this in Python? > > Ok, I just double-checked the source for plot_wireframe(). It does not perform any broadcasting (which I consider to be a bug). Until it is fixed, you will have to do the broadcasting yourself: X= np.ones((1, 45)) Y= np.zeros((32, 1)) x, y = np.broadcast_arrays(X, Y) Which produces x and y with the same shapes, and their values duplicated in the direction the array was "expanded". Pass those into plot_wireframe(). Ben Root |
|
From: surfcast23 <sur...@gm...> - 2012-08-03 01:39:24
|
Okay thank you! The Matlab code I am basing this on takes arrays of different shapes with different sized elements ie x = 1 512 y = 101 1 and I guess automatically makes the the same shape. Can you point me in the direction of documentation that will explain how I can do this in Python? Benjamin Root-2 wrote: > > On Thursday, August 2, 2012, surfcast23 wrote: > >> >> >> >> surfcast23 wrote: >> > >> > In the documentation it says that Axes3D.plot_wireframe(X, Y, Z, *args, >> > **kwargs) takes 2D arrays as the first two arguments. Do the arrays >> have >> > to have the same size dimensions? >> > >> > >> >> Any one know? > > > Working from memory, the first two have to at least be "broadcastable" > into > the shape of Z. But absolutely, if x, y, and z are 2d, they have to be > the > same shape. It makes no sense otherwise. > > Cheers! > Ben Root > > ------------------------------------------------------------------------------ > Live Security Virtual Conference > Exclusive live event will cover all the ways today's security and > threat landscape has changed and how IT managers can respond. Discussions > will include endpoint security, mobile security and the latest in malware > threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > _______________________________________________ > Matplotlib-users mailing list > Mat...@li... > https://lists.sourceforge.net/lists/listinfo/matplotlib-users > > -- View this message in context: http://old.nabble.com/Size-of-array-elements-when-using-Axes3D.plot_wireframe%28X%2C-Y%2C-Z%2C-*args%2C-**kwargs%29-tp34243823p34248914.html Sent from the matplotlib - users mailing list archive at Nabble.com. |
|
From: Perry G. <pe...@st...> - 2012-08-03 00:31:23
|
On Aug 2, 2012, at 5:25 PM, John Hunter wrote: > > I also extend my heartfelt thanks to Perry Greenfield and STScI. They > have been supporting matplotlib since 2004 with ideas, code and > developer resources. They employ Michael currently, and are part of > the reason why he is able to take on the leadership of this large > project. > John, it has been our great fortune have joined the matplotlib effort. It saved us an enormous effort. It has been an incredible pleasure working with you. I'm not sure you realize how very much Mike and I hope you can rejoin the matplotlib effort. It will always be there for you. Perry |
|
From: Michael D. <md...@st...> - 2012-08-02 23:58:44
|
I couldn't put an exact date on when John began matplotlib, but its sourceforge repository was registered in June of 2003. Python 2.2 was the latest version available. Microsoft Windows XP was on the shelves, Mac OS X was new to the scene, and Linux had yet to be made easy by the likes of Ubuntu and Fedora. Facebook, Twitter and the smartphone weren't yet available. And the idea of richly interactive and productive applications running in the cloud was still considered crazy. A decade is a long time for an open source project, and it's a testament to John's hard work and keen decision-making that matplotlib has thrived for so long and grown into such a large community of smart and talented users and developers. Bravo, John. To remain relevant in its second decade, matplotlib is being pulled simultaneously in two directions. On the one hand, to handle larger and more complex data, it needs to get closer to the hardware to make better use of GPUs and multicore CPUs. On the other hand, it needs to become a first-class member of the most important GUI of our time, the web browser, and to do so without sacrificing any of the power and flexibility it gets from being a Python library. Challenging stuff, but not unattainable given the enormous brain trust we've got here. Procedurally, one thing I've been feeling rather acutely lately is that the firehose of github issues is not always the best way to track larger changes. I'd like to propose that we set up an informal system of "Matplotlib Enhancement Proposals" (MEPs) to manage larger changes to matplotlib that might cut across a number of different subsystems. Numpy puts these in their source code repository, but we may just want to use the github wiki to make it even easier for non-developers to contribute ideas. I'm not envisioning anything super formal here -- just something to keep track of the larger goals that won't get lost among hundreds of smaller issues. Details can be discussed here (I'd love suggestions from other projects) and I'll set something up soon. I'm sure we all have our own pet projects we'd like to do "time willing" and I look forward to discussing and making headway on some of those. And back to the immediate future: we've got a release to get out: the first release to support Python 3.x. Exciting times. Details to follow in another e-mail thread. John, thanks again for the honor and I hope I can follow your example of leadership. They are big shoes to fill. Mike On 08/02/2012 05:25 PM, John Hunter wrote: > It is a great honor for me to announce that Michael Droettboom has > agreed to take on the role of lead developer of matplotlib. Since > Michael joined the project in 2007, he has been responsible for much > of the code that brought matplotlib from being an excellent tool to a > world class one. No one in the world understands the code from the > inside out like he does, and many of his contributions, while often > unseen at the surface, have laid the foundation for matplotlib to > reach further into the wild and wonderful things it can now do. > > To name a few of his contributions: generic, optimized caching > transformations; dramatic backend simplification and rationalization; > countless optimizations; implementation of Knuth mathtex layouts; > python3 support, and dolphins! I like to tell people Michael codes > with the force of ten men, and he's an incredible asset to our team. > > My role has been significantly diminished of late -- although I have > been the nominal lead developer, in practice I have been a release > manager. Unfortunately, I need to take some time to focus on family > health issues, but will continue to follow development and make > contributions as I can. We'll be looking for a release manager soon, > and if you are interested in stepping up, we'll welcome the effort. > We have a wonderful distributed development team using github pull > requests, and the line between core developers, project leaders and > plain-ole contributers is blurry. But I think it helps to have > someone thinking about the project as a whole, who is willing and able > to make decisions when necessary, and no one is better suited to doing > this than Michael. > > I also extend my heartfelt thanks to Perry Greenfield and STScI. They > have been supporting matplotlib since 2004 with ideas, code and > developer resources. They employ Michael currently, and are part of > the reason why he is able to take on the leadership of this large > project. > > Michael, many thanks. > > > > ------------------------------------------------------------------------------ > Live Security Virtual Conference > Exclusive live event will cover all the ways today's security and > threat landscape has changed and how IT managers can respond. Discussions > will include endpoint security, mobile security and the latest in malware > threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > > > _______________________________________________ > Matplotlib-users mailing list > Mat...@li... > https://lists.sourceforge.net/lists/listinfo/matplotlib-users |
|
From: Benjamin R. <ben...@ou...> - 2012-08-02 23:42:41
|
On Thursday, August 2, 2012, surfcast23 wrote: > > > > surfcast23 wrote: > > > > In the documentation it says that Axes3D.plot_wireframe(X, Y, Z, *args, > > **kwargs) takes 2D arrays as the first two arguments. Do the arrays have > > to have the same size dimensions? > > > > > > Any one know? Working from memory, the first two have to at least be "broadcastable" into the shape of Z. But absolutely, if x, y, and z are 2d, they have to be the same shape. It makes no sense otherwise. Cheers! Ben Root |
|
From: Chad P. <par...@gm...> - 2012-08-02 23:21:36
|
Hello everyone- I'm a new Python/Matplotlib user, but I have quite a bit of plotting experience with octave/matlab and gnuplot. So, I apologize in advance if my python style is terrible and if I give you all the wrong information! I'm having a problem saving figures that contain images as eps files when my x-axis is a date/time axis. The trouble is that in the resulting eps file, the image data is shifted relative to the axis. I've attached two images as an example. In the .png file the alignment is correct and in the eps file it's not. The png is also nearly identical to what I get when I plot to the screen. The script I wrote to generate these plots is at the end of this message. It's worth noting that the two output images are identical if the x-axis is simply numerical and not a time series. I'm using python 2.7.3 and Matplotlib 1.1.0 Some Google searches dug up this old thread, however, the shift that I'm experiencing seems to be much greater, so I don't know if it's related: http://old.nabble.com/Saving-as-eps-file-shifts-image--td29232680.html Can anyone help me solve this? Thanks in advance, --Chad Here is a minimal script that I used to generate these plots: import matplotlib.pyplot as plt import matplotlib.dates as dts from matplotlib.colors import LogNorm imgData = [[1.0/x + 1.0/y for x in range(1,100)] for y in range(1,100)] tMin=dts.epoch2num(1343947266) tMax=dts.epoch2num(1343947266+100) axImg=plt.subplot(111) axImg.imshow(imgData, norm=LogNorm(),extent=(tMin,tMax,1,100),\ interpolation='none', origin="upper") axImg.xaxis_date() axImg.set_aspect('auto') plt.savefig("imageshift.png") plt.savefig("imageshift.eps") |
|
From: surfcast23 <sur...@gm...> - 2012-08-02 23:15:10
|
surfcast23 wrote: > > In the documentation it says that Axes3D.plot_wireframe(X, Y, Z, *args, > **kwargs) takes 2D arrays as the first two arguments. Do the arrays have > to have the same size dimensions? > > Any one know? -- View this message in context: http://old.nabble.com/Size-of-array-elements-when-using-Axes3D.plot_wireframe%28X%2C-Y%2C-Z%2C-*args%2C-**kwargs%29-tp34243823p34248559.html Sent from the matplotlib - users mailing list archive at Nabble.com. |
|
From: Fernando P. <fpe...@gm...> - 2012-08-02 23:11:18
|
Dear Colleagues, the SIAM CSE13 conference will be held next year in Boston, and this is a conference that is well suited for much of the type of work that goes on in the open source scientific Python development community (and Julia). The conference is co-chaired by Hans-Petter Langtangen, well known around these parts for his several books on scientific computing with Python and for having led a campus-wide adoption of Python as the core computational foundation across the University of Oslo. I am also on the program committee, as well as Randy LeVeque and other Python-friendly folks. An excellent way to participate is to organize a one- or two-part minisymposium on a specific topic with a group of related speakers (instructions at http://www.siam.org/meetings/cse13/submissions.php). Please note that the MS deadline is fast approaching: August 13, 2012. If you have any further questions, don't hesitate to contact me or one of the other organizers if you feel they can address your concerns more directly: "Fernando Perez" <Fer...@be...> "Randy LeVeque" <rj...@am...> (Reproducible research track) "Hans Petter Langtangen" <hp...@si...> (Conference co-chair) "Karen Willcox" <kwi...@mi...> (conference chair) ---------- Forwarded message ---------- From: Karen Willcox <kwi...@mi...> Date: Tue, Jul 24, 2012 at 6:08 AM Subject: [SIAM-CSE] SIAM Conference on Computational Science & Engineering Submission Deadlines Approaching! To: SIA...@si... *SIAM Conference on Computational Science & Engineering (CSE13)* February 25-March 1, 2013 The Westin Boston Waterfront, Boston, Massachusetts, USA**** ** ** SUBMISSION DEADLINES ARE APPROACHING!**** August 13, 2012: Minisymposium proposals September 10, 2012: Abstracts for contributed and minisymposium speakers**** Visit http://www.siam.org/meetings/cse13/submissions.php to submit.**** ** ** Twitter hashtag: #SIAMcse13**** ** ** For more information about the conference, visit * http://www.siam.org/meetings/cse13/* or contact SIAM Conference Department at mee...@si....**** -- Karen Willcox Professor and Associate Department Head Department of Aeronautics and Astronautics, MIT http://acdl.mit.edu/willcox.html _______________________________________________ SIAM-CSE mailing list To post messages to the list please send them to: SIA...@si... http://lists.siam.org/mailman/listinfo/siam-cse |
|
From: John H. <jd...@gm...> - 2012-08-02 21:26:14
|
It is a great honor for me to announce that Michael Droettboom has agreed to take on the role of lead developer of matplotlib. Since Michael joined the project in 2007, he has been responsible for much of the code that brought matplotlib from being an excellent tool to a world class one. No one in the world understands the code from the inside out like he does, and many of his contributions, while often unseen at the surface, have laid the foundation for matplotlib to reach further into the wild and wonderful things it can now do. To name a few of his contributions: generic, optimized caching transformations; dramatic backend simplification and rationalization; countless optimizations; implementation of Knuth mathtex layouts; python3 support, and dolphins! I like to tell people Michael codes with the force of ten men, and he's an incredible asset to our team. My role has been significantly diminished of late -- although I have been the nominal lead developer, in practice I have been a release manager. Unfortunately, I need to take some time to focus on family health issues, but will continue to follow development and make contributions as I can. We'll be looking for a release manager soon, and if you are interested in stepping up, we'll welcome the effort. We have a wonderful distributed development team using github pull requests, and the line between core developers, project leaders and plain-ole contributers is blurry. But I think it helps to have someone thinking about the project as a whole, who is willing and able to make decisions when necessary, and no one is better suited to doing this than Michael. I also extend my heartfelt thanks to Perry Greenfield and STScI. They have been supporting matplotlib since 2004 with ideas, code and developer resources. They employ Michael currently, and are part of the reason why he is able to take on the leadership of this large project. Michael, many thanks. |