Closed cfrioux closed 8 months ago
Hi @cfrioux, Hi @ArnaudBelcour,
This would be great! When will this option become available?
Best regards,
Noor Alsmadi
Creating a list of targets for all the reachable compounds of the community (community scope) is not implemented yet. I do not have time to properly include it in m2m these days, but, I've got a snippet to do it, if you're interested.
import sys
import json
from metage2metabo.sbml_management import create_species_sbml
# inputs
jsonfile = sys.argv[1]
output_file_sbml = sys.argv[2]
# read scope file and retrieve targets
with open(jsonfile, "r") as f:
raw = json.load(f)
targets = raw["com_scope"]
# create a SBML with the targets
create_species_sbml(targets, output_file_sbml)
You write the above script in a file (let's say scope_to_targets.py
) and call it this way:
python scope_to_targets.py community_analysis/comm_scopes.json community_analysis/comm_scopes.sbml
Added in #61.
An interesting analysis can be to select minimal communities suitable to sustain the producibility of all compounds the community can produce. This consists in building a set of targets consisting of the metabolites in the community scope (community metabolic potential).
An easy solution can be to create a SBML file containing compounds occurring in the community scope (
community_analysis/comm_scopes.json
).