Re: groupby() seems slow

2007-10-16 Thread Raymond Hettinger
On Oct 15, 8:02 pm, 7stud <[EMAIL PROTECTED]> wrote: > t = timeit.Timer("test3()", "from __main__ import test3, key, data") > print t.timeit() > t = timeit.Timer("test1()", "from __main__ import test1, data") > print t.timeit() > > --output:--- > 42.791079998 > 19.0128788948 > > I thought groupby()

Re: groupby() seems slow

2007-10-15 Thread George Sakkis
On Oct 15, 11:02 pm, 7stud <[EMAIL PROTECTED]> wrote: > I'm applying groupby() in a very simplistic way to split up some data, > but when I timeit against another method, it takes twice as long. The > following groupby() code groups the data between the "" strings: > > data = [ > "1.5","","2.5","3