Displaying 2 results from an estimated 2 matches for "stoichiometric".
2010 Jul 16
1
Creating symbolic expressions in R
..., I'm trying to use the law of mass action
(the details of which aren't really important) to structure a vector
of rate equation which will be passed into an ODE function and solved
with associated functions from 'deSolve.' Roughly what this entails
is scanning through a very large stoichiometric matrix containing
integers which map metabolites to reactions and then assembling a
series of monomials that describe the rates of the reactions. I'm
running into trouble because R does not like doing numerical
operations on characters, but I need the rate to be in symbolic form.
Below I'v...
2010 Jul 21
0
Converting Between Character and Numeric Objects
...o convert a vector of string objects to a numeric object by
initializing the variables with values. I use the function below to scan
through a matrix and create mass action flux relationships:
makeMassActionFluxes = function(sMatrix) {
#Allocate a matrix with identical dimensions as the inputted stoichiometric
matrix
temp = matrix(nrow = dim(sMatrix)[1], ncol = dim(sMatrix)[2])
velocities = vector(length = dim(sMatrix)[2])
## This series of 'for' loops scans the stoichiometrix matrix looking for
negative integers.
## Once it identifies a negative integer it pulls the row name and
exponentiates...