changeObjFunc: Sets/changes the Objective Function

Description Usage Arguments Details Value Author(s) See Also Examples

View source: R/changeObjFunc.R

Description

The function changeObjFunc changes or sets the objective function for a specified model.

Usage

1

Arguments

model

An object of class modelorg.

react

An object of class reactId, character or integer. Specifies the fluxes (variables) for which to change the objective coefficients.

obj_coef

A numerical vector with length equal to the number of reaction id's given in argument react containing the objective coefficients.
Default: a value of one for each reaction given in argument react.

Details

The argument react will be evaluated by the function checkReactId. The return value is used to change the objective function.

All reactions not given in argument react will get an objective value of zero.

Value

Returns the given model containing the new objective function.

Author(s)

Gabriel Gelius-Dietrich <geliudie@uni-duesseldorf.de>

Maintainer: Mayo Roettger <mayo.roettger@hhu.de>

See Also

checkReactId

Examples

1
2
3
  ## sets the objective function to the ATP maintenance reaction:
  data(Ec_core)
  Ec_new <- changeObjFunc(Ec_core, "ATPM")

Example output

Loading required package: Matrix
Loading required package: lattice

sybil documentation built on May 31, 2021, 5:08 p.m.