Question: Retriving compounds name from KEGG IDs
1
gravatar for glady
2.8 years ago by
glady240
glady240 wrote:

Dear all, I have list of KEGG IDs for metabolites (compounds) and I want to get the name of the all the compounds from that list. So please suggest me what should I do??? Thanks

gene • 2.8k views
ADD COMMENTlink modified 8 months ago by Biostar ♦♦ 20 • written 2.8 years ago by glady240

yes something like that but for my list of IDs. Thanks

ADD REPLYlink written 2.8 years ago by glady240

Sorry, but what you are asking for are 10 lines of code in python(maximum) and even less in R

ADD REPLYlink written 2.8 years ago by Girolamo140

It is more helpful to provide actual code rather than a statement about how small the needed code is.

ADD REPLYlink written 2.8 years ago by genomax64k

Can you please post your sample input ?

ADD REPLYlink modified 2.8 years ago • written 2.8 years ago by EagleEye6.2k
4
gravatar for EagleEye
2.8 years ago by
EagleEye6.2k
Sweden
EagleEye6.2k wrote:

I hope this helps,

1.make a file 'sample.list' with the list of compound IDs you have,

cat sample.list

C00001

C00002

C00003

C00004

C00005

C00006

C00007

2.And then run the following CURL command below.

curl -g -s -S http://rest.kegg.jp/list/compound | grep -f sample.list | sed "s/cpd\://" > sample_extracted.table.txt

SAMPLE OUTPUT:

C00001  H2O; Water
C00002  ATP; Adenosine 5'-triphosphate
C00003  NAD+; NAD; Nicotinamide adenine dinucleotide; DPN; Diphosphopyridine nucleotide; Nadide; beta-NAD+
C00004  NADH; DPNH; Reduced nicotinamide adenine dinucleotide
C00005  NADPH; TPNH; Reduced nicotinamide adenine dinucleotide phosphate
C00006  NADP+; NADP; Nicotinamide adenine dinucleotide phosphate; beta-Nicotinamide adenine dinucleotide phosphate; TPN; Triphosphopyridine nucleotide; beta-NADP+
C00007  Oxygen; O2

I assume, I understand your question properly.

ADD COMMENTlink modified 2.8 years ago • written 2.8 years ago by EagleEye6.2k

Dear EagleEye thank you for your comments

And you got me right. I am trying to run the above command but in windows it is saying that grep is not recognized as internal or external command., so is there any alternative for that. please let me know.

Thanks

ADD REPLYlink written 2.8 years ago by glady240
1

You can install cygwin to get a unix like environment on windows or better still run linux in a virtual machine (e.g. virtual box).

ADD REPLYlink written 2.8 years ago by genomax64k

You can follow as genomax2 suggested or simple is to run on Linux.

ADD REPLYlink written 2.8 years ago by EagleEye6.2k

Please upvote if this helps, so that other people know that the problem has been solved.

ADD REPLYlink written 2.8 years ago by EagleEye6.2k

Thank you for the reply.

I just upvoted. Thanks

ADD REPLYlink written 2.8 years ago by glady240
0
gravatar for mgalactus
2.8 years ago by
mgalactus720
United Kingdom
mgalactus720 wrote:

You can either search for them in the KEGG database website, or use something more automated like the KEGG REST API (in this specific case you need the "get" method).

Suppose you are interested in the following three compound IDs:

  • C00818
  • C00140
  • C00259

Simply go to this webpage (have a look at how the URL has been constructed): http://rest.kegg.jp/get/C00259+C00140+C00818

ADD COMMENTlink written 2.8 years ago by mgalactus720

Dear Mgalactus, thank you for your reply. The method you suggested, gives the details of the compounds in query. but I have a list of more than 2000 metabolites IDs. In that case its very difficult to get the name and details. So is there any way to get the result output in tabular format like as in *.csv format.

Thanks in advance

ADD REPLYlink written 2.8 years ago by glady240
0
gravatar for Girolamo
2.8 years ago by
Girolamo140
Italia
Girolamo140 wrote:

like this? http://rest.kegg.jp/list/compound

ADD COMMENTlink written 2.8 years ago by Girolamo140
Please log in to add an answer.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.3.0
Traffic: 1078 users visited in the last hour