On 2/9/10 4:57 PM, Mark Larsen wrote: >> If the above does not work, how do I access items in the returned list? > > I frequently work like this: > > an_r_list=robjects.r('list(one=1,two=2)') > list_names = [name for name in robjects.r.names(an_r_list)] > value, = an_r_list[list_names.index('one')]
Nice one. If rpy2 objects implemented the method "index", this would even me more straightforward. As this is straightforward to implement, I'll put it on the TODO list for the 2.1.0beta L. > ------------------------------------------------------------------------------ > The Planet: dedicated and managed hosting, cloud storage, colocation > Stay online with enterprise data centers and the best network in the business > Choose flexible plans and management services without long-term contracts > Personal 24x7 support from experience hosting pros just a phone call away. > http://p.sf.net/sfu/theplanet-com > _______________________________________________ > rpy-list mailing list > rpy-list@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/rpy-list ------------------------------------------------------------------------------ The Planet: dedicated and managed hosting, cloud storage, colocation Stay online with enterprise data centers and the best network in the business Choose flexible plans and management services without long-term contracts Personal 24x7 support from experience hosting pros just a phone call away. http://p.sf.net/sfu/theplanet-com _______________________________________________ rpy-list mailing list rpy-list@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/rpy-list