Thank you. It worked
• 0 views
•
link
I have a list of protein IDs. An example list is as follows. How can I use esearch esearch -db protein -query <listids> in protein database to identify those that are not present in the protein database?
ADK95960.1
PQL24628.1
AVM48340.1
ADK95748.1
EFX40722.1
AKU69507.1
AVM47886.1
ADK96247.1
NOT9000.1
You can do it with esummary:
If your accesions are in file called ids then the following will fetch the json format for each:
URL='https://eutils.ncbi.nlm.nih.gov/entrez/eutils/esummary.fcgi?db=protein\&format=json\&id='
cat ids | parallel -j 1 curl -s ${URL}{} > results.txt
where the results.txt file will contain lines such as:
{"header":{"type":"esummary","version":"0.3"},"error":"Invalid uid NOT9000.1 at position=0","result":{"uids":[]}}
for the invalid entries.
Thank you. It worked
Log in to answer this question.