7
$\begingroup$

I am using PythonCyc API in order to write a query for metabolites in BioCyc. The purpose of this API is to communicate with the database software of BioCyc- Pathway Tools. Pathway Tools is in lisp therefore, PythonCyc creates a bridge between python and common lisp. To use this this API one must first create a PGDB object with a specified organism ID (orgid). In the example below I create a PGDB with orgid "meta". After this, I am able to call methods from PythonCyc with this object:

import sys
import pythoncyc
#this creates PGDB object associated with meta(MetaCyc)
meta = pythoncyc.select_organism('meta')
#lists pathways of specified compound
pathways = meta.pathways_of_compound('sucrose')
print pathways

The query for the metabolite above, 'sucrose', provides a list a pathways:

[u'|PWY-7347|', u'|SUCSYN-PWY|', u'|PWY-7238|', u'|PWY-6527|', u'|PWY-5343|', u'|PWY-3801|', u'|PWY-7345|', u'|PWY-862|', u'|SUCUTIL-PWY|', u'|PWY66-373|', u'|PWY-621|', u'|PWY-822|', u'|SUCROSEUTIL2-PWY|', u'|PWY-6525|', u'|PWY-6524|', u'|PWY-5337|', u'|PWY-5384|']

However if I switch this metabolite name to a common amino acid name, such as 'valine':

import sys
import pythoncyc
#this creates PGDB object associated with meta(MetaCyc)
meta = pythoncyc.select_organism('meta')
#lists pathways of specified compound
pathways = meta.pathways_of_compound('valine')
print pathways

The query provides an error message that states "non coercible frame", which means it cannot find this ID. This is a common metabolite, just as sucrose, which should very well have pathway entries in database, however there are none found with this method. I have also tried synonyms of valine and other methods such as "all_pathways(cpds)" stated in API, which give me the same error message. What is the reason for this? Does BioCyc not list any pathways for amino acids? Or am I using an incorrect method to access amino acid information?

Link to PythonCyc API

$\endgroup$
1
  • 4
    $\begingroup$ Hi astrika, thanks for your question and welcome to Bioinformatics Stack Exchange. I've had a glance over this question, and it looks like it has the potential to get good answers: it is well-researched, with a good story, and a specific question. I look forward to seeing more questions from you in the future. $\endgroup$
    – gringer
    Jun 9 '17 at 21:23
3
$\begingroup$

UPD: As suggested by Llopis, maybe the correct identifier is VAL?

I think there is no metabolite with such name in the database. I tried their search, the correct name seems to be L-valine. I expect that they use similar naming for other amino acids. If you cannot find something, you can use their compound search through the website.

$\endgroup$
2
  • $\begingroup$ I have tried 'L-valine' in the script above and it has also gave me the same error. I am aware it is possible to search in the site, however for my purpose I must write a query. My purpose is to obtain possible pathway networks for a given metabolics dataset $\endgroup$ Jun 12 '17 at 23:33
  • $\begingroup$ @astrika maybe the name is Protein-L-valine, or VAL. One thing is how they store things an another is how they show them. Sorry I didn't test how to search using python $\endgroup$
    – llrs
    Jul 13 '17 at 7:31
3
$\begingroup$

Pathway-tools has a unique identifier (called a Frame-ID) for each metabolite in its database. You can get the list of all compounds with this api call:

all_cpds = meta.get_class_all_instances('|Compounds|')

for each compound, you can also get its common name, or all its synonyms:

cpd_names = {} for cpd_frame_id in all_cpds: cpd_names[cpd_frame_id] = meta.get_name_string(cpd_frame_id)

$\endgroup$
0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.