Monday, April 28, 2008

Getting identifiers for a list of genes

If you want to to quickly get identifiers for a long list of items you can use the following command, which uses wget to repeatedly query the API.

cat protein_names.txt | xargs -i wget -nv -O - \
'http://stitch.embl.de/api/tsv-no-header/resolve?identifier={}&species=4932&echo_query=1' \
> protein_identifiers.tsv
I've also introduced another parameter, echo_query, so that you can see your query item in the output.

No comments:

Post a Comment

Note: Only a member of this blog may post a comment.