Skip to main content
Topic: KEGG searching (Read 5992 times) previous topic - next topic

KEGG searching

Hello,

I was wondering if there is a way to search the KEGG database similar to the search scripts for METLIN through XCMS?  And if not, (I am also new to the KEGG database) how can you search KEGG by molecular weight?  I have been searching and no luck- thank you for any help!

Ashley

Re: KEGG searching

Reply #1
Hi Ashley,

I've been working on doing a cool little function for this for some time however there is a package called KEGGSOAP downloadable from bioconductor http://http://www.bioconductor.org/packages/2.4/bioc/html/KEGGSOAP.html.
If you load up KEGGSOAP and use the following code it should work (required internet connection):

Code: [Select]
library(KEGGSOAP)

search.compounds.by.mass(89.0932, 0.1)
## [1] "cpd:C00041" "cpd:C00099" "cpd:C00133" "cpd:C00213" "cpd:C01401" "cpd:C01444" "cpd:C01537" "cpd:C02116"
## [9] "cpd:C06383" "cpd:C11488"

bget("-f m cpd:C00041") ## gives the mol file for plotting the molecule with RCDK ([url]http://cran.r-project.org/web/packages/rcdk/index.html[/url])

molD<-bget("cpd:C00041") ## this will give you the full listing
molName<-strsplit(strsplit(molD, "n")[[1]][2],  "\s+", perl=T)[[1]][2]
molName
##[1] "L-Alanine;"

This can be a very messy way but it gets the job done. If you're going to put this into a for loop be careful of the multiple results returned. I'm pretty sure that the results are returned in order for the original mass. Also remember KEGG searches neutral masses!!

The method that I working on in xcms will hopefully get a better name and have a choice between the different results. I'll spend some time and get the function working and into the next release of xcms. I'll update here when I do.

Paul

EDIT:
Just reread your Q and thought you might also want this
http://http://www.genome.jp/ligand-bin/result?db=compound&pid=130909468912976&show=weight,structure&q=89%20-%2090

This search is done from the http://http://www.genome.jp/kegg/ligand.html page about half way down it says "Search COMPOUND" then use the drop down box to get "Exact mass"
~~
H. Paul Benton
Scripps Research Institute
If you have an error with XCMS Online please send me the JOBID and submit an error via the XCMS Online contact page

Re: KEGG searching

Reply #2
Hey Paul,

Thank you for the reply ,it was extremely helpful.  I haven't gotten the KEGGSOAP to function properly, but I'll mess around with it a little bit more.  I look forward to the XCMS update, thanks again!

Ashley

 

Re: KEGG searching

Reply #3
Quote
KEGGSOAP to function properly

Whats the error message or is it just not working?? Let me know.  ;)
~~
H. Paul Benton
Scripps Research Institute
If you have an error with XCMS Online please send me the JOBID and submit an error via the XCMS Online contact page