## The examples here require the package glpkAPI to be
## installed. If that package is not available, you have to set
## the argument 'solver' (the default is: solver = "glpk").
## load the example data set
data(Ec_core)
lowbnd(Ec_core)[react_id(Ec_core)=='EX_glc(e)']=-10;
lowbnd(Ec_core)[react_id(Ec_core)=='EX_o2(e)']=-18;
## run dynamicFBA(), Ec_df will be an object of class \code{\link{optsol_dynamicFBA}}
Ec_df <- dynamicFBA(Ec_core,substrateRxns={'EX_glc(e)'},initConcentrations=10,initBiomass=.035,timeStep=.25,nSteps=20,verbose=3)
## plot biomass and reactions
plot(Ec_df,plotRxns=c('EX_glc(e)','EX_ac(e)'));Run the code above in your browser using DataLab