[Biopython-dev] [BioPython] about the SeqRecord slicing
Jose Blanca
jblanca at btc.upv.es
Fri Mar 27 14:02:57 UTC 2009
On Friday 27 March 2009 14:57:30 Peter wrote:
> How would you make it optional? As an extra non-standard argument
> to __getitem__? e.g.something like my_record[10:50, annotation=False]?
> That seems nasty.
That's very nasty, not pythonic, and adds complexity to the api.
> I am sympathetic to dropping the annotations dictionary when creating
> a "child" SeqRecord when slicing its parent. There is also the database
> cross reference list (which i forgot on my last email). Again, I wouldn't
> object to dropping this for a sliced sub-record.
>
> If we did drop the annotations and dbxrefs when slicing, the user can
> manually choose to explicitly copy them from the parent object if the
> do want them.
I also think that dropping all that stuff when slicing or adding is the best
behaviour.
--
Jose M. Blanca Postigo
Instituto Universitario de Conservacion y
Mejora de la Agrodiversidad Valenciana (COMAV)
Universidad Politecnica de Valencia (UPV)
Edificio CPI (Ciudad Politecnica de la Innovacion), 8E
46022 Valencia (SPAIN)
Tlf.:+34-96-3877000 (ext 88473)
More information about the Biopython-dev
mailing list