[Numpy-discussion] recarray slow?
Wed Jul 21 14:12:14 CDT 2010
I have an recarray -- the first column is date.
I have the following function to compute the number of unique dates in
my data set:
def byName(): return(len(list(set(d['Date'])) ))
Question: is the string 'Date' looked up at each iteration? If so,
this is dumb, but explains my horrible performance.
Or, is there a better way to code the above?
Can I convert this to something indexed by column number and convert
'Date' to column number "0" upfront? Would this help with speed?
More information about the NumPy-Discussion