As the first step in the decommissioning of the site has been converted to read-only mode.

Here are some tips for How to share your SAS knowledge with your professional network.

Tips:Simulate generalized gamma distributed data for PROC LIFEREG

From sasCommunity
Jump to: navigation, search

The generalized gamma distribution can be used to model gamma distributed survival times in PROC LIFEREG as well as Weibull [where Shape=1], exponential [Shape=1, Scale=1] and lognormal [Shape=0] survival times.

To simulate a data set that will generate results in PROC LIFEREG with specific values for the shape, scale, intercept and other parameters, the following code can be used:


where X is the generated survival time and xb can be the intercept, for intercept-only models, or a linear combination of covariates, such as:

   xb = intercept + beta1*x1 + beta2*x2;

where x1 and x2 are covariates and beta1 and beta2 are the corresponding parameter estimates.