Re: [Numpy-discussion] Fill a particular value in the place of number satisfying certain condition by another number in an array.

2011-08-01 Thread Miguel de Val-Borro
Dear Dileep, the numpy.where function returns the elements from A or 0 depending if the condition in the first argument is satisfied: B = np.where(A >= 0, A, 0) Miguel On Mon, Aug 01, 2011 at 03:01:13PM +0530, dileep kunjaai wrote: > Dear sir, >How can we fill a particular value in the place

Re: [Numpy-discussion] reading in files with fixed with format

2011-07-07 Thread Miguel de Val-Borro
The function numpy.genfromtxt reads text files into arrays. There is an example on how to deal with fixed-width columns using the delimiter argument in the docstring and in the I/O chapter of the user guide: http://docs.scipy.org/doc/numpy/user/basics.io.genfromtxt.html#the-delimiter-argument Migu

Re: [Numpy-discussion] Problem with Numpy and array

2011-05-12 Thread Miguel de Val-Borro
On Thu, May 12, 2011 at 12:21:46PM +0200, Claudia Chan Yone wrote: > Hi, > > I have a problem with the Numpy module, but I think it is a very basic issue > for many of you... > I have a file with numerical data (2 columns, and 5 lignes) as : > 1 2 > 3 4 > ... ... > > And I woulid like to convert

Re: [Numpy-discussion] help me

2011-03-25 Thread Miguel de Val-Borro
On Fri, Mar 25, 2011 at 05:28:50PM +0530, dileep kunjaai wrote: > Dear sir, > I have a numpy array,,. in which i have to choose only different values > only, > For example > > Let A= [ 20. 21. 22. 23. 24. 25. 20. 21. 22. 23. 24. 25. > 20. 21. 22. 23. 24. 25. 20. 21. 22. 23.

Re: [Numpy-discussion] Anybody going to PyCon?

2011-03-07 Thread Miguel de Val-Borro
Hi Gökhan, I will present a poster about astronomical data reduction and visualization on Sunday. I will arrive to Atlanta on Wednesday morning to attend a couple of tutorials before the conference and look forward to participating in sprints or other activities. Regards, Miguel On Mon, Mar 07,