Hi Charles, Isn't it possible to give a default argument when you declare a Column Desciptor? I haven't tried this, but something like
> class Particle(IsDescription) > pressure = Float64Col(dflt=5.0) should give you a table description that can be used to create a table with one float col that defaults to 5.0. Cheers, Gabriel On Wed, 2010-11-24 at 21:21 -0500, Charles Krohn wrote: > Hello list, > > I need to create a large table where all values in each column are set > to some initial value... thus all rows are identical. I thought > something like this would work: > > r = t.row > r['col'] = 3.14159 > for i in range(table_len): > r.append() > > But this just fills the first row. The remaining rows are blank. > I've resorted to filling in each row before each append, but this > seems needlessly slow. Is there a faster way to do this? Ideally I > would be able to specify default values for each column in the table > description. For some reason I thought this was possible, but I don't > see any mention in the documentation. > > Thanks, > > - Charles > ------------------------------------------------------------------------------ > Increase Visibility of Your 3D Game App & Earn a Chance To Win $500! > Tap into the largest installed PC base & get more eyes on your game by > optimizing for Intel(R) Graphics Technology. Get started today with the > Intel(R) Software Partner Program. Five $500 cash prizes are up for grabs. > http://p.sf.net/sfu/intelisp-dev2dev > _______________________________________________ Pytables-users mailing list > Pytables-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/pytables-users ------------------------------------------------------------------------------ Increase Visibility of Your 3D Game App & Earn a Chance To Win $500! Tap into the largest installed PC base & get more eyes on your game by optimizing for Intel(R) Graphics Technology. Get started today with the Intel(R) Software Partner Program. Five $500 cash prizes are up for grabs. http://p.sf.net/sfu/intelisp-dev2dev _______________________________________________ Pytables-users mailing list Pytables-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/pytables-users