search for: dmet1

Displaying 1 result from an estimated 1 matches for "dmet1".

Did you mean: dmeth
2010 Jul 21
0
Converting Between Character and Numeric Objects
...erating function to initialize values for the met variables. state = c(met1 = 10, met2 = 10, met3 = 10, met4 = 10, met5 = 10) parameters = 1 ODE = function(t, state, parameters, S, velocity) { with(as.list(c(state, parameters, S, velocity)), { des = S %*% v #The products should look like this: #dmet1 = (-1)*met1^1*met2^1 + (0)*met2^1*met3^1 + (2)*met3^1 #Return list(des) }) } When I call 'makeODE' I get the following error (which I expected): Error in S %*% v : requires numeric/complex matrix/vector arguments I'm wondering if there is an easy way to remove the quotes on the el...