kaihami
kaihami

Reputation: 815

Convert e-utils command to equivalent in Bio.Entrez (BioPython)

I'm having some trouble to connect each command using BioPython.

Can someone help me to transform this command line to the equivalent using BioPython?

esearch -db assembly -query "GCF_002514765.1" | elink -target biosample | efetch -format xml

Thanks,

Upvotes: 1

Views: 59

Answers (1)

Aureliano Guedes
Aureliano Guedes

Reputation: 785

Esummary may solve it.

from Bio import Entrez

acc = "GCF_002514765.1"
search = Entrez.read(Entrez.esearch(db="assembly", term=acc))
summary = Entrez.read(Entrez.esummary(db="assembly",id=idsearch['IdList'],report="full"))

Upvotes: 1

Related Questions