For this example we consider the phenobarbital data from Grasela and Donn (1985), which are also analyzed by Davidian and Gallant (1993). These are routine clinical data collected from 59 newborn infants treated with phenobarbital during the first 16 days after birth.

Program

The data appear as Data Set 15.7, “Phenobarbital,” in Appendix 2, “Data Sets,” and are processed with the following statements:

data pheno;

   input indiv time dose weight apgar conc;

   retain cursub .;

   if cursub ne indiv then do;

      newsub = 1;

      cursub = indiv;

   end;

   else newsub = 0;

   if (apgar < 5) then apgarlow = 1;

   else apgarlow = 0;

   tlag = lag(time);

   if (newsub=1) then tlag = 0;

   drop apgar cursub; ...

Get SAS for Mixed Models, Second Edition, 2nd Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.