kair 0.5.0

COnstraint Based Reconstruction and Analysis (COBRA) in Rust
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
extern crate good_lp;
extern crate kair;

use good_lp::coin_cbc;
use kair::{flux_analysis::fba, ModelLp};
use std::str::FromStr;

fn main() {
    let file_str = std::fs::read_to_string("examples/EcoliCore.xml").unwrap();
    let mut model = ModelLp::from_str(&file_str).unwrap();
    // println!("{:?}", model.metabolites_lp);
    for (name, val) in fba(&mut model, coin_cbc).unwrap().iter() {
        println!("{} = {}", name, val)
    }
}