The SEQDESIGN Procedure

Applicable Regression Parameter Tests and Sample Size Computation

The SEQDESIGN procedure provides sample size computation for tests of a regression parameter in three regression models: normal regression, logistic regression, and proportional hazards regression.

To test a parameter $\beta _{1}$ in a regression model, the variance of the parameter estimate $\hat{\beta }_{1}$ is needed for the sample size computation. In a simple regression model with one covariate X1, the variance of $\hat{\beta }_{1}$ is inversely related to the variance of X1, $\sigma ^{2}_{x}$. That is,

\[  \mr {Var} ( \hat{\beta }_{1} ) \,  \propto \,  \frac{1}{N \,  \sigma ^{2}_{x}}  \]

for the normal regression and logistic regression models, where N is the sample size, and

\[  \mr {Var} ( \hat{\beta }_{1} ) \,  \propto \,  \frac{1}{D \,  \sigma ^{2}_{x}}  \]

for the proportional hazards regression model, where D is the number of events.

For a regression model with more than one covariate, the variance of $\hat{\beta }_{1}$ for the normal regression and logistic regression models is inversely related to the variance of X1 after adjusting for other covariates. That is,

\[  \mr {Var} ( \hat{\beta }_{1} ) \,  \propto \,  \frac{1}{N \,  (1 - r^{2}_{x}) \,  \sigma ^{2}_{x}}  \]

where $\hat{\beta }_{1}$ is the estimate of the parameter ${\beta }_{1}$ in the model and $r^{2}_{x}$ is the R square from the regression of $\Variable{X1}$ on other covariates—that is, the proportion of the variance $\sigma ^{2}_{x}$ explained by these covariates.

Similarly, for a proportional hazards regression model,

\[  \mr {Var} ( \hat{\beta }_{1} ) \,  \propto \,  \frac{1}{D \,  (1 - r^{2}_{x}) \,  \sigma ^{2}_{x}}  \]

Thus, with the derived maximum information, the required sample size or number of events can also be computed for the testing of a parameter in a regression model with covariates.

Test for a Parameter in the Regression Model

The MODEL=REG option in the SAMPLESIZE statement derives the sample size required for a Z test of a normal regression. For a normal linear regression model, the response variable is normally distributed with the mean equal to a linear function of the explanatory variables and the constant variance $\sigma ^{2}$.

The normal linear model is

\[  \mb {y} \sim N \left( \,  \mb {X} \bbeta , \,  {\sigma }^{2}_{y} \,  \mb {I}_{(N)} \right)  \]

where $\mb {Y}_{(N \times 1)}$ is the vector of the N observed responses, $\mb {X}_{(N \times p)}$ is the design matrix for these N observations, $\bbeta _{(p \times 1)}$ is the parameter vector, and $\mb {I}_{(N)}$ is the $(N \times N)$ identity matrix.

The least squares estimate is

\[  \hat{\bbeta } = { \left( \mb {X}’ \mb {X} \right) }^{-1} \mb {X}’ \mb {Y}  \]

and is normally distributed with mean $\bbeta $ and variance

\[  \mr {Var}( \hat{\bbeta } )= \sigma ^{2}_{y} {( \mb {X}’ \mb {X} )}^{-1}  \]

For a model with only one covariate X1,

\[  {\hat\beta }_{1} \sim N \left( \,  \beta _1, \,  \mr {Var} ( {\hat\beta }_{1} ) \right)  \]

where the variance

\[  \mr {Var} ( {\hat\beta }_{1} ) = {I^{-1}_{\beta _{1}}} = \sigma ^{2}_{y} \, \,  \frac{1}{N \,  \sigma ^{2}_{x}}  \]

Thus, with the derived maximum information $I_{X}=I_{\beta _{1}}$, the required sample size is given by

\[  N = I_{X} \, \,  \frac{\sigma ^{2}_{y}}{\sigma ^{2}_{x}}  \]

For a normal linear model with more than one covariate, the variance of a single parameter $\beta _{1}$ is

\[  \mr {Var}( {\hat{\beta }}_{1} ) = \sigma ^{2}_{y} \,  {( \mb {X}’ \mb {X} )}^{-1}_{(11)} = \sigma ^{2}_{y} \,  \frac{1}{N \,  \sigma ^{2}_{x} \,  (1 - r^{2}_{x}) }  \]

where ${( \mb {X}’ \mb {X} )}^{-1}_{(11)}$ is the diagonal element of the ${( \mb {X}’ \mb {X} )}^{-1}$ matrix corresponding to the parameter $\beta _{1}$, $\sigma ^{2}_{x}$ is the variance of the variable X1, and $r^{2}_{x}$ is the proportion of variance of X1 explained by other covariates. The value $\sigma ^{2}_{x} \,  (1 - r^{2}_{x})$ represents the variance of X1 after adjusting for all other covariates.

Thus, with the derived maximum information $I_{X}$, the required sample size is

\[  N = I_{X} \, \,  \frac{\sigma ^{2}_{y}}{(1 - r^{2}_{x}) \,  \sigma ^{2}_{x}}  \]

In the SEQDESIGN procedure, you can specify the MODEL=REG( VARIANCE=$\sigma ^{2}_{y}$ XVARIANCE=$\sigma ^{2}_{x}$ XRSQUARE=$r^{2}_{x}$) option in the SAMPLESIZE statement to compute the required total sample size and individual sample size at each stage. A SAS procedure such as PROC REG can be used to compute the parameter estimate and its standard error at each stage.

Test for a Parameter in the Logistic Regression Model

The MODEL=LOGISTIC option in the SAMPLESIZE statement derives the sample size required for a Z test of a logistic regression parameter. The linear logistic model has the form

\[  \mr {logit} (p) = \mr {log} \left( \frac{p}{1-p} \right) = \mb {x} \bbeta  \]

where p is the response probability to be modeled and $\bbeta $ is a vector of parameters.

Following the derivation in the section Test for a Parameter in the Regression Model, the required sample size for testing a parameter in $\bbeta $ is given by

\[  N = I_{X} \, \,  \frac{\sigma ^{2}_{y}}{(1 - r^{2}_{x}) \,  \sigma ^{2}_{x}}  \]

With the variance of the logit response, $\sigma ^{2}_{y} = 1/(p(1-p))$,

\[  N = I_{X} \, \,  \frac{1}{p(1-p)} \, \,  \frac{1}{(1 - r^{2}_{x}) \,  \sigma ^{2}_{x}}  \]

where $\sigma ^{2}_{x}$ is the variance of X and $r^{2}_{x}$ is the proportion of variance explained by other covariates.

In the SEQDESIGN procedure, you can specify the MODEL=LOGISTIC( PROP=p XVARIANCE=$\sigma ^{2}_{x}$ XRSQUARE=$r^{2}_{x}$) option in the SAMPLESIZE statement to compute the required total sample size and individual sample size at each stage.

A SAS procedure such as PROC LOGISTIC can be used to compute the parameter estimate and its standard error at each stage.

Test for a Parameter in the Proportional Hazards Regression Model

The MODEL=PHREG option in the SAMPLESIZE statement derives the number of events required for a Z test of a proportional hazards regression parameter. For analyses of survival data, Cox’s semiparametric model is often used to examine the effect of explanatory variables on hazard rates. The survival time of each observation in the population is assumed to follow its own hazard function, $h_{i}(t)$, expressed as

\[  h_{i}(t)= h(t;\mb {X}_{i}) = h_{0}(t) \  \mr {exp}(\mb {X}’_{i}\bbeta )  \]

where $h_{0}(t)$ is an arbitrary and unspecified baseline hazard function, $\mb {x}_ i$ is the vector of explanatory variables for the ith individual, and $\bbeta $ is the vector of regression parameters associated with the explanatory variables.

Hsieh and Lavori (2000, p. 553) show that the required number of events for testing a parameter in $\bbeta $, $\beta _1$, associated with the variable X1 is given by

\[  D_{X} = I_{X} \, \,  \frac{1}{(1 - r^{2}_{x}) \, \,  \sigma ^{2}_{x}}  \]

where $\sigma ^{2}_{x}$ is the variance of X1 and $r^{2}_{x}$ is the proportion of variance of X1 explained by other covariates.

In the SEQDESIGN procedure, you can specify the MODEL=PHREG( XVARIANCE=$\sigma ^{2}_{x}$ XRSQUARE=$r^{2}_{x}$) option in the SAMPLESIZE statement to compute the required number of events and individual number of events at each stage.

A SAS procedure such as PROC PHREG can be used to compute the parameter estimate and its standard error at each stage.

Note that for a two-sample test, X1 is an indicator variable and is the only covariate in the model. Thus, if the two sample sizes are equal, then the variance $\sigma ^{2}_{x}=1/4$ and the required number of events for testing the parameter $\beta _{1}$ is given by

\[  D_{X} = I_{X} \, \,  \frac{1}{\sigma ^{2}_{x}} = 4 \,  I_{X}  \]

See the section Input Number of Events for Fixed-Sample Design for a detailed description of the sample size computation that uses hazard rates, accrual rate, and accrual time.