Cobra Run Fba
cobra_run_fba
Open in the interactive browser →
Run flux balance analysis with optional objective, constraints and medium; returns status, objective value, uptake/secretion fluxes, the limiting medium components (supplied nutrients at their uptake bound, by shadow price) and top fluxes.
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
constraints |
object | no | per-call bounds: {reaction_id: [lb, ub]} |
include_fluxes |
boolean | no | inline the full flux vector (<= 500 reactions); it is always available as the fluxes_resource CSV |
medium |
object | no | {exchange_id: positive uptake rate} (mmol/gDW/h). Merged onto the model's default medium: listed uptakes override, all other default uptakes stay open, 0 closes an exchange |
medium_replace |
boolean | no | true = COBRApy replace semantics: exchanges not listed in medium are closed |
model_id |
string | yes | bundled model id (e_coli_core, iML1515, iMM904, iCHOv1) or a session_model_id from cobra_load_model |
objective |
any | no | reaction id or {reaction_id: coefficient}; default: model objective |
solver |
string | no | LP solver (default hybrid = HiGHS, MIT; glpk excluded: GPL-free image) |
top_n |
integer | no |
Examples
Run flux balance analysis with optional objective, constraints and medium; returns status, objective value, uptake/secretion fluxes, the limiting medium components (supplied nutrients at their uptake bound, by shadow price) and top fluxes (declared example)
Prompt: “Run flux balance analysis with optional objective, constraints and medium; returns status, objective value, uptake/secretion fluxes, the limiting medium components (supplied nutrients at their uptake bound, by shadow price) and top fluxes using cobra_run_fba with arguments {"model_id": "e_coli_core"}”
Run flux balance analysis with optional objective, constraints and medium; returns status, objective value, uptake/secretion fluxes, the limiting medium components (supplied nutrients at their uptake bound, by shadow price) and top fluxes (minimal call)
Prompt: “Call cobra_run_fba and summarise the result.”
cobracobra_run_fba