turn on suggestions

Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

Find a Community

- Home
- /
- Analytics
- /
- Stat Procs
- /
- PROC MODEL: Estimating ODE parameters

Topic Options

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content

03-03-2010 11:53 AM

Hello,

I am a SAS beginner, so please excuse me if my question is silly.

I'm trying to estimate the parameters of a ODE system with four equations and eight parameters. Each of the 4 ODEs look something like this:

dxi/dt = f(param1, param2, param3, param3, input1, input2, input3, input4, x1, x2, x3, x4)

I have a data set that includes the values of the input variables and the dependent variables (x1, x2, etc.) at each discrete time point (t=1, ... 60). Thus, the data is a table that has 8 columns and 60 rows.

If I manually choose the parameter values, I am able to successfully simulate the model using something like this

PROC MODEL

...

SOLVE x1 x2 x3 x4 / time = ...;

RUN;

However, when I try to estimate the parameters, I get an error: "At OLS Iteration 0 there are 1 nonmissing observations available. At least 3 are needed to compute the next iteration."

I also get a warning: "Missing value encountered for initial DERT.x1 at ..." In my data, the input variables are not known at each time but I get the same warning even when I fill the missing values with some arbitrary numbers.

My code is:

PROC MODEL

DATA=... /* the data includes, time, input and actual values of x */

OUT=...

OUTALL;

parameters param1=... param2=... ...;

dependent x1=... x2=... ... ;

DERT.x1 = ...

...

DERT.x4 = ...

fit x1 x2 x3 x4 / time=... dynamic SUR;

RUN;

Can anyone tell me what I'm doing wrong?

Thank you!

I am a SAS beginner, so please excuse me if my question is silly.

I'm trying to estimate the parameters of a ODE system with four equations and eight parameters. Each of the 4 ODEs look something like this:

dxi/dt = f(param1, param2, param3, param3, input1, input2, input3, input4, x1, x2, x3, x4)

I have a data set that includes the values of the input variables and the dependent variables (x1, x2, etc.) at each discrete time point (t=1, ... 60). Thus, the data is a table that has 8 columns and 60 rows.

If I manually choose the parameter values, I am able to successfully simulate the model using something like this

PROC MODEL

...

SOLVE x1 x2 x3 x4 / time = ...;

RUN;

However, when I try to estimate the parameters, I get an error: "At OLS Iteration 0 there are 1 nonmissing observations available. At least 3 are needed to compute the next iteration."

I also get a warning: "Missing value encountered for initial DERT.x1 at ..." In my data, the input variables are not known at each time but I get the same warning even when I fill the missing values with some arbitrary numbers.

My code is:

PROC MODEL

DATA=... /* the data includes, time, input and actual values of x */

OUT=...

OUTALL;

parameters param1=... param2=... ...;

dependent x1=... x2=... ... ;

DERT.x1 = ...

...

DERT.x4 = ...

fit x1 x2 x3 x4 / time=... dynamic SUR;

RUN;

Can anyone tell me what I'm doing wrong?

Thank you!

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content

03-04-2010 04:37 AM

Hello,

As a side note...

When I do not include the input vectors, i.e., when I assign constant values to the variables

input1 = const1;

input2 = const2;

etc.

The code works - well almost. I get the warning "The covariance across equations (the S matrix) is singular. A generalized inverse was computed by setting to zero the part of the S matrix for the following 1 equations whose residuals are linearly dependent with residuals from earlier equations: x2" I suppose this does not come as a surprise, given that the ODEs make little sense if the input is constant.

So maybe the problem is with how I deal with the input variables? I just refer to them in the code using the same variable name with which they appear in the data.

I would very much appreciate if anyone had even just a vague idea of what might be the problem...

As a side note...

When I do not include the input vectors, i.e., when I assign constant values to the variables

input1 = const1;

input2 = const2;

etc.

The code works - well almost. I get the warning "The covariance across equations (the S matrix) is singular. A generalized inverse was computed by setting to zero the part of the S matrix for the following 1 equations whose residuals are linearly dependent with residuals from earlier equations: x2" I suppose this does not come as a surprise, given that the ODEs make little sense if the input is constant.

So maybe the problem is with how I deal with the input variables? I just refer to them in the code using the same variable name with which they appear in the data.

I would very much appreciate if anyone had even just a vague idea of what might be the problem...