Re: [Numpy-discussion] Installing Numpy on Python 2.3 Windows

2007-07-30 Thread Lisandro Dalcin
On 7/25/07, Amir Hirsch <[EMAIL PROTECTED]> wrote: > The Python 2.3 installation I am using came with OpenOffice.org 2.2 and it > must > not have registered python with Windows. I require PyUNO and Numpy (and > PyOpenGL and Ctypes) to work together for the application I am developing and > PyUno

Re: [Numpy-discussion] column_stack with mixed data types

2007-07-30 Thread Robert Kern
Ryan Krauss wrote: > I just tend to think in terms of lists rather than tuples. Why is a > tuple a more reasonable choice than a list? (I'm really asking and > not being argumentative, since you can't hear my tone.) The key thing is that the type of the container of records is different from the

Re: [Numpy-discussion] column_stack with mixed data types

2007-07-30 Thread Ryan Krauss
I just tend to think in terms of lists rather than tuples. Why is a tuple a more reasonable choice than a list? (I'm really asking and not being argumentative, since you can't hear my tone.) Ryan On 7/30/07, Robert Kern <[EMAIL PROTECTED]> wrote: > Ryan Krauss wrote: > > In writing a function t

Re: [Numpy-discussion] column_stack with mixed data types

2007-07-30 Thread Robert Kern
Ryan Krauss wrote: > In writing a function to parse my data, I ran into some unexpected > behavior. Is it intentional that a recarray can only be created by a > list of tuples and not by a list of lists? Yeah. The array() constructor needs some information for it to work its magic. Requiring tupl

Re: [Numpy-discussion] column_stack with mixed data types

2007-07-30 Thread Ryan Krauss
In writing a function to parse my data, I ran into some unexpected behavior. Is it intentional that a recarray can only be created by a list of tuples and not by a list of lists? Here is what I ran into: ipdb>biglist[0:10] Out[68]: [[7, 20.0, 'HE 4.0 pcf', 'Flat', 'Small', 32.6875, 2.75, ''], [

[Numpy-discussion] column_stack with mixed data types

2007-07-30 Thread Ryan Krauss
I have data in a spreadsheet where the first column is an integer. the second is a float, columns 3-5 are strings, and columns 6 and 7 are floats. I have each column as a list, but when I use column_stack, I get back a 2D array of strings. What is the easiest way to get a recarray out of this lis

Re: [Numpy-discussion] Memory leak for in-place Numeric+numpy addition

2007-07-30 Thread Travis Oliphant
Thomas J. Duck wrote: > Hi, > > There seems to be a memory leak when arrays are added in-place > for mixed Numeric/numpy applications. For example, memory usage > quickly ramps up when the following program is executed: > > > import Numeric,numpy > x = Numeric.zeros((2000,2000),typeco

Re: [Numpy-discussion] How to implement a 'pivot table?'

2007-07-30 Thread Geoffrey Zhu
Hi Timothy, On 7/30/07, Timothy Hochberg <[EMAIL PROTECTED]> wrote: > > > On 7/30/07, Geoffrey Zhu <[EMAIL PROTECTED]> wrote: > > Hi Everyone, > > > > I am wondering what is the best (and fast) way to build a pivot table > > aside from the 'brute force way?' > > What's the brute force way? It's ea

Re: [Numpy-discussion] Downsampling array, retaining min and max values in window

2007-07-30 Thread Travis Oliphant
Matthieu Brucher wrote: > Hi, > > I think you should look into scipy.ndimage which has minimum_filter > and maximum_filter > > Matthieu > > 2007/7/24, Ludwig M Brinckmann < [EMAIL PROTECTED] > >: > > Hi there, > > I have a large array, lets say 4 * 512, which

Re: [Numpy-discussion] How to implement a 'pivot table?'

2007-07-30 Thread Timothy Hochberg
On 7/30/07, Geoffrey Zhu <[EMAIL PROTECTED]> wrote: > > Hi Everyone, > > I am wondering what is the best (and fast) way to build a pivot table > aside from the 'brute force way?' What's the brute force way? It's easier to offer an improved suggestion if we know what we're trying to beat. I want

Re: [Numpy-discussion] reading 10 bit raw data into an array

2007-07-30 Thread Travis Oliphant
Danny Chan wrote: > Hi all! > I'm trying to read a data file that contains a raw image file. Every > pixel is assigned a value from 0 to 1023, and all pixels are stored from > top left to bottom right pixel in binary format in this file. I know the > width and the height of the image, so all tha

[Numpy-discussion] How to implement a 'pivot table?'

2007-07-30 Thread Geoffrey Zhu
Hi Everyone, I am wondering what is the best (and fast) way to build a pivot table aside from the 'brute force way?' I want to transform an numpy array into a pivot table. For example, if I have a numpy array like below: Region Date # of Units -------

Re: [Numpy-discussion] reading 10 bit raw data into an array

2007-07-30 Thread Stefan van der Walt
On Mon, Jul 30, 2007 at 04:01:46PM +0200, Danny Chan wrote: > I'm trying to read a data file that contains a raw image file. Every pixel is > assigned a value from 0 to 1023, and all pixels are stored from top left to > bottom right pixel in binary format in this file. I know the width and the > he

[Numpy-discussion] reading 10 bit raw data into an array

2007-07-30 Thread Danny Chan
Hi all! I'm trying to read a data file that contains a raw image file. Every pixel is assigned a value from 0 to 1023, and all pixels are stored from top left to bottom right pixel in binary format in this file. I know the width and the height of the image, so all that would be required is to re

[Numpy-discussion] epydoc documentation of numpy package

2007-07-30 Thread Sebastian Haase
Hi, For general interest - I just found this web page: http://stsdas.stsci.edu/pyraf/stscidocs/imagestats_pkg/imagestats_api/numpy-module.html I seems to me to be a nice overview of all functions in numpy. Question: is there an "official" version of this on the scipy.org site ? Or a link? Comm