Re: [Numpy-discussion] NumPy beta release plan

2006-07-10 Thread Christian Kristukat
Charles R Harris gmail.com> writes: > > > Hi, > > On 7/9/06, Robert Kern gmail.com> wrote: > Christian Kristukat wrote:> Robert Kern gmail.com> writes:>>> I believe that Debian recently changed its configuration to default to > >> /usr/local (for good reason!). Perhaps that is causing what

[Numpy-discussion] Converting a list

2006-07-10 Thread Nils Wagner
Hi all, I have a list consisting of arrays of different size data = [array([-1.+0.j, -1.+0.j, -1.6667+0.j]), array([-2.+0.j, -2.-0.6667j, -2.-1.j]), array([-2.-2.j, -1.-2.j, -0.6667-2.j]), array([ 0.-2.j, 0.-1.6667j, 0.-1.

Re: [Numpy-discussion] Converting a list

2006-07-10 Thread Robert Kern
Nils Wagner wrote: > Hi all, > > I have a list consisting of arrays of different size > > data = [array([-1.+0.j, -1.+0.j, -1.6667+0.j]), > array([-2.+0.j, -2.-0.6667j, -2.-1.j]), > array([-2.-2.j, -1.-2.j, -0.6667-2.j]), array([ > 0.-2

[Numpy-discussion] Number of digits

2006-07-10 Thread Nils Wagner
Hi all, how can I increase the number of digits in the output of str(.) ? >>> lam**2 493.48022005446808 >>> str(lam**2) '493.480220054' '493.4802200544680' would be fine. Nils - Using Tomcat but need to do more? Need to

Re: [Numpy-discussion] Number of digits

2006-07-10 Thread David Douard
On Mon, Jul 10, 2006 at 02:33:52PM +0200, Nils Wagner wrote: > Hi all, > > how can I increase the number of digits in the output of str(.) ? > > >>> lam**2 > 493.48022005446808 > >>> str(lam**2) > '493.480220054' > > '493.4802200544680' would be fine. Maybe something like >>> '%.13f'%(lam**2)

Re: [Numpy-discussion] Number of digits

2006-07-10 Thread Tim Hochberg
Nils Wagner wrote: > Hi all, > > how can I increase the number of digits in the output of str(.) ? > You can't as far as I know. For floats, you can use "%.nf". For example: "%.13f" % 493.4802200544680 -tim > lam**2 > 493.48022005446808 > str(lam**2)

Re: [Numpy-discussion] Number of digits

2006-07-10 Thread Robert Kern
Tim Hochberg wrote: > Nils Wagner wrote: >> Hi all, >> >> how can I increase the number of digits in the output of str(.) ? >> > You can't as far as I know. For floats, you can use "%.nf". For example: > > "%.13f" % 493.4802200544680 The problem is is that he doesn't have a float. He has one o

Re: [Numpy-discussion] Number of digits

2006-07-10 Thread David Douard
On Mon, Jul 10, 2006 at 08:46:33AM -0500, Robert Kern wrote: > Tim Hochberg wrote: > > Nils Wagner wrote: > >> Hi all, > >> > >> how can I increase the number of digits in the output of str(.) ? > >> > > You can't as far as I know. For floats, you can use "%.nf". For example: > > > > "%.13f" %

Re: [Numpy-discussion] Number of digits

2006-07-10 Thread Robert Kern
Robert Kern wrote: > Tim Hochberg wrote: >> Nils Wagner wrote: >>> Hi all, >>> >>> how can I increase the number of digits in the output of str(.) ? >>> >> You can't as far as I know. For floats, you can use "%.nf". For example: >> >> "%.13f" % 493.4802200544680 > > The problem is is that he do

Re: [Numpy-discussion] Testing a self-compiled numpy

2006-07-10 Thread Bryce Hendrix
Keith Goodman wrote: The only thing is that the numpy installer built by the windows instructions on the Wiki doesn't give you an option of where to install numpy. It installs straight to {PYTHON_DIR}\lib\site-packages\numpy. (The command suggested by the wiki is: c:\path\to\python.

Re: [Numpy-discussion] Number of digits

2006-07-10 Thread Robert Kern
David Douard wrote: > On Mon, Jul 10, 2006 at 08:46:33AM -0500, Robert Kern wrote: >> Tim Hochberg wrote: >>> Nils Wagner wrote: Hi all, how can I increase the number of digits in the output of str(.) ? >>> You can't as far as I know. For floats, you can use "%.nf". For examp

Re: [Numpy-discussion] PyObject arrays, pickling, tofile

2006-07-10 Thread Tom Denniston
Travis, Thanks for your help. Sorry for taking so long to get back to you. I wasn't on email for a few days. I seem to be able to pickle and restore PyObject arrays but then concatenates and takes give me the following error: TypeError: fields with object members not yet supported. What is ev

Re: [Numpy-discussion] recarray field names

2006-07-10 Thread John Parejko
Howdy! I just wanted to voice my agreement with this statment by Erin Sheldon: > I brought up the issue a while back of having a simple way to > access the field names of an array. The quick summary: accessing > field names has some oddness that needs cleaning up. Sometimes a['name'], sometim

Re: [Numpy-discussion] Converting a list

2006-07-10 Thread Pierre GM
On Monday 10 July 2006 05:57, Robert Kern wrote: > Nils Wagner wrote: > > Hi all, > > > > I have a list consisting of arrays of different size ... > > The error message is unhelpful, certainly, but the *fact* that an exception > is raised is not a bug. Attempting to build an array from a list of s

Re: [Numpy-discussion] NumPy beta release plan

2006-07-10 Thread Russell E. Owen
In article <[EMAIL PROTECTED]>, Travis Oliphant <[EMAIL PROTECTED]> wrote: > 3) C-API names have prefix PyArray_ (like always), NPY_ or npy_. > >The NPY_ and npy_ prefixes are new and were done to remove the >likelihood of name collisions when NumPy is used with another >library.

Re: [Numpy-discussion] .M .A .T .H attribute result

2006-07-10 Thread Keith Goodman
On 7/7/06, Travis Oliphant <[EMAIL PROTECTED]> wrote: > a numpy.matlib module was started to store matrix versions of the > standard array-creation functions and mat was re-labeled to "asmatrix" > so that a copy is not made by default. Holy crap! It works. This is great. Thank you. >> import nu

Re: [Numpy-discussion] Args for rand and randn: call for a vote

2006-07-10 Thread Christopher Barker
Ed Schofield wrote: > * Should numpy.rand and numpy.randn accept sequences of dimensions as > arguments, like rand((3,3)), as an alternative to rand(3,3)? +1 +1 for ONLY allowing tuples. Or just get rid of it. -Chris -- Christopher Barker, Ph.D. Oceanographer

Re: [Numpy-discussion] Converting a list

2006-07-10 Thread Robert Kern
Pierre GM wrote: > On Monday 10 July 2006 05:57, Robert Kern wrote: >> Nils Wagner wrote: >>> Hi all, >>> >>> I have a list consisting of arrays of different size > ... >> The error message is unhelpful, certainly, but the *fact* that an exception >> is raised is not a bug. > > Attempting to build

Re: [Numpy-discussion] NumPy beta release plan

2006-07-10 Thread Travis Oliphant
Christian Kristukat wrote: >Travis Oliphant ieee.org> writes: > > > >>Some of you may have noticed that things have been changing rapidly in >>the NumPy world (if you were out of the office in June then all the >>activity may seem overwhelming). >> >>All of this activity is based on the fact

Re: [Numpy-discussion] recarray field names

2006-07-10 Thread Travis Oliphant
John Parejko wrote: >Howdy! I just wanted to voice my agreement with this statment by Erin Sheldon: > > > I brought up the issue a while back of having a simple way to > > access the field names of an array. The quick summary: accessing > > field names has some oddness that needs cleaning up. > >

Re: [Numpy-discussion] NumPy beta release plan

2006-07-10 Thread Travis Oliphant
Russell E. Owen wrote: >In article <[EMAIL PROTECTED]>, > Travis Oliphant <[EMAIL PROTECTED]> wrote: > > > >>3) C-API names have prefix PyArray_ (like always), NPY_ or npy_. >> >> The NPY_ and npy_ prefixes are new and were done to remove the >> likelihood of name collisions when NumPy is

Re: [Numpy-discussion] NumPy beta release plan

2006-07-10 Thread Sasha
I would like to add my voice to a call for single prefix (I like PyArray_ for everything, but can live with npy_). Presumably npy_ vs. NPY_ variation is supposed to distinguish between macros and C language elements, but as long as the stem is properly capitalized, I don't see a problem of using

Re: [Numpy-discussion] recarray field names

2006-07-10 Thread Travis Oliphant
John Parejko wrote: >Howdy! I just wanted to voice my agreement with this statment by Erin Sheldon: > > > I brought up the issue a while back of having a simple way to > > access the field names of an array. The quick summary: accessing > > field names has some oddness that needs cleaning up. > >

Re: [Numpy-discussion] NumPy beta release plan

2006-07-10 Thread Travis Oliphant
Sasha wrote: >I would like to add my voice to a call for single prefix (I like >PyArray_ for everything, but can live with npy_). Presumably npy_ >vs. NPY_ variation is supposed to distinguish between macros and C >language elements, but as long as the stem is properly capitalized, I >don't see

[Numpy-discussion] Strange error taking log of PyObject array

2006-07-10 Thread Tom Denniston
The following works on a float array but not an object array. It gives a very strange error message. (Pdb) numpy.log(numpy.array([19155613843.7], dtype=object)) *** AttributeError: 'float' object has no attribute 'log' (Pdb) numpy.log([19155613843.7]) array([ 23.67586166]) -

Re: [Numpy-discussion] Strange error taking log of PyObject array

2006-07-10 Thread Travis Oliphant
Tom Denniston wrote: > The following works on a float array but not an object array. It > gives a very strange error message. > > (Pdb) numpy.log(numpy.array([19155613843.7], dtype=object)) > *** AttributeError: 'float' object has no attribute 'log' > This is expected behavior. For object arra

[Numpy-discussion] rotten foul. spotted teensy

2006-07-10 Thread lighting displays
G0ldmark Industries, Inc ( G D K I ) THIS ST()CK IS E>http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 ___ Numpy-discussion mailing list Numpy-discussion@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/numpy-dis

Re: [Numpy-discussion] recarray field names

2006-07-10 Thread Erin Sheldon
Just tested the lastest SVN and it works as advertised. Thanks Travis. An unrelated question: why does this work for arrays but not recarrays? In [24]: mydescriptor = [('age',float64),('Nchildren',int8),('weight',float32)] In [25]: a = array([(64,2,75.0),(25,0,60.0)], dtype=mydescriptor)

Re: [Numpy-discussion] recarray field names

2006-07-10 Thread Travis Oliphant
Erin Sheldon wrote: > Just tested the lastest SVN and it works as advertised. Thanks > Travis. > > An unrelated question: why does this work for arrays but not recarrays? > > > In [24]: mydescriptor = > [('age',float64),('Nchildren',int8),('weight',float32)] > > In [25]: a = array([(64,2,75.0)

Re: [Numpy-discussion] Converting a list

2006-07-10 Thread Nadav Horesh
Do you mean: >> map(shape, data) -Original Message- From: [EMAIL PROTECTED] on behalf of Nils Wagner Sent: Mon 10-Jul-06 12:26 To: numpy-discussion@lists.sourceforge.net Cc: Subject:[Numpy-discussion] Converting a list Hi all, I have a list consisting of arrays of d

Re: [Numpy-discussion] Strange error taking log of PyObject array

2006-07-10 Thread Tim Hochberg
Travis Oliphant wrote: > Tom Denniston wrote: > >> The following works on a float array but not an object array. It >> gives a very strange error message. >> >> (Pdb) numpy.log(numpy.array([19155613843.7], dtype=object)) >> *** AttributeError: 'float' object has no attribute 'log' >> >>

Re: [Numpy-discussion] recarray field names

2006-07-10 Thread Erin Sheldon
On 7/11/06, Travis Oliphant <[EMAIL PROTECTED]> wrote: > Erin Sheldon wrote: > > Just tested the lastest SVN and it works as advertised. Thanks > > Travis. > > > > An unrelated question: why does this work for arrays but not recarrays? > > > > > > In [24]: mydescriptor = > > [('age',float64),('N

[Numpy-discussion] Keyword argument order changed in records.py

2006-07-10 Thread Travis Oliphant
In an effort to preserve consistency, I made a change to the keyword argument order in the functions in records.py. In addition, all of the functions now take a dtype= keyword argument. This keyword argument is placed first along with other needed keyword arguments. When the dtype keyword i