[Biopython] Question about efetch output format
bar tomas
bartomas at gmail.com
Fri Sep 4 04:21:04 EDT 2009
Many thanks. My mistake, I must've copied it badly from the doc.
On Thu, Sep 3, 2009 at 5:38 PM, Peter <biopython at maubp.freeserve.co.uk>wrote:
> On Thu, Sep 3, 2009 at 5:06 PM, jorma kala<jjkk73 at gmail.com> wrote:
> > Hi,
> > I'm trying to retrieve a record from protein database (I found the record
> id
> > by running Entrez.esearch)
> >
> > handle = Entrez.efetch(db="protein", id='483329',mode='xml')
> > print handle.read()
> > Although I specify xml mode, the result comes in a quite confusing format
> > using braces (I've pasted a snippet at the end of the email)
> >
> > Do you know what I should do to get it in xml?
> > Many thanks
>
> You've got the default ASN.1 output. You need to use "retmode" not "mode",
>
> from Bio import Entrez
> handle = Entrez.efetch(db="protein", id='483329',retmode='xml')
> print handle.read()
>
> I thought both the Biopython documentation and the NCBI documentation
> was clear on this - maybe you found a typo? Please let us know if there is
> an error in any of the documentation or examples.
>
> Thanks
>
> Peter
>
> _______________________________________________
> Biopython mailing list - Biopython at lists.open-bio.org
> http://lists.open-bio.org/mailman/listinfo/biopython
>
More information about the Biopython
mailing list