Hi SAS community
I have data over time for ~200 participants. For each participant, I want to fit the same model, but I have a different set of initial conditions for the PROC NLIN routine (derived by looking at data for each paritcipant). How do I get this to work (code below)? Any help really appreciate. I keep get error like this: NOTE: DER.a not initialized or missing. It will be computed automatically. NOTE: DER.b not initialized or missing. It will be computed automatically. NOTE: DER.c not initialized or missing. It will be computed automatically. NOTE: DER.d not initialized or missing. It will be computed automatically. WARNING: Zero observations could be evaluated. NOTE: The data set WORK.PARAMS_OUT_4 has 0 observations and 9 variables.
data initial_params;
set in.initial_params;
nf+1;
call symputx("last_nf",nf);
run;
data participant_data;
set in.participant_data;
run;
%macro fit;
%do j=1 %to &last_nf.;
data _null_;
set initial_params;
where nf=&j;
call symputx("beta10",beta10);
call symputx("beta20",beta20);
call symputx("beta30",beta30); call symputx("beta40".beta40);
call symputx("participant",subject);
run;
proc nlin data = participant_data g4 plots = fit maxiter = 50 outest = params_out_&j.;
where subject="&participant";
parameters a = &beta10. &beta20. = -3 c = &beta30. d = &beta40.;
model response = a*exp(time/b) + c*time + d;
run;
%end;
%mend;
%fit;
suggesting what I do wrong would be very helpful to me!
... View more