BookmarkSubscribeRSS Feed
☑ This topic is solved. Need further help from the community? Please sign in and ask a new question.
Jack2012
Obsidian | Level 7

Dear All, 

 

I have a question regard to the calculation of the type I error as shown in the snapshot below, anyone could help me out ? In SAS I know there is procedures about alpha spending. But how to get the type i error if we don't adjust the alpha as shown in the hightlighted area.

 

Thanks . 

 

Jack

 

Jack2012_0-1657977487583.png

 

1 ACCEPTED SOLUTION

Accepted Solutions
FreelanceReinh
Jade | Level 19

Hello @Jack2012,

 

In C. Jennison, B.W. Turnbull (2000): Group Sequential Methods with Applications to Clinical Trials (which is frequently referred to in the PROC SEQDESIGN documentation), section "2.4 Pocock's test" I found a fairly simple (N(0,1)-distributed) test statistic Zk (formula (2.4), p. 25) based on normal distributions, which I simulated with the code below and reproduced the type I error probabilities for k=1, 2, 5 and 10 of your table (k = #interim analyses). These appear to be largely independent of all three parameters used: the sample size increment n (=m in the book) and the normal distribution parameters m (=mA=mB under H0), s (=s). (Actually, it should be possible to compute these probabilities from the multivariate normal distribution of the vector (Z1, Z2, ..., ZK), but I haven't tried to do so.)

%let n=20; /* arbitrary sample size increment per group */
%let m=0;  /* arbitrary mean and */
%let s=1;  /* arbitrary std of the common normal distr. of the trt. groups A, B under H0 */

/* Simulation of the absolute value c[k] of statistic Z_k, 1<=k<=10, from Jennison/Turnbull, p. 25 */

data test(drop=j);
call streaminit(27182818);
array c[10] _temporary_;
do i=1 to 100000;
  call missing(a, b, of c[*]);
  do k=1 to 10;
    do j=1 to &n;
      a+rand('normal',&m,&s);
      b+rand('normal',&m,&s);
    end;
    c[k]=1/sqrt(2*&n*k*&s**2)*abs(a-b);
    r=(max(of c[*])>probit(0.975)); /* indicator for rejection of H0 at any stage 1, ..., k */
    output;
  end;
end;
run;

/* Computation of relative frequencies of indicator variable r
   (approximating the type I error probabilities) */

proc summary data=test nway;
class k;
var r;
output out=want(drop=_:) mean=p;
run;

proc print data=want noobs;
where k in (1, 2, 5, 10);
run;

Result:

 k       p

 1    0.05054
 2    0.08340
 5    0.14176
10    0.19369

Jennison and Turnbull cite a 1969 paper reporting 0.142 for k=5.

View solution in original post

3 REPLIES 3
ballardw
Super User

Insufficient information. Type error results depend on specific test conducted, data and model. You have provided none of those elements.

 

Different procedures often use different options to display/control Type error information.

FreelanceReinh
Jade | Level 19

Hello @Jack2012,

 

In C. Jennison, B.W. Turnbull (2000): Group Sequential Methods with Applications to Clinical Trials (which is frequently referred to in the PROC SEQDESIGN documentation), section "2.4 Pocock's test" I found a fairly simple (N(0,1)-distributed) test statistic Zk (formula (2.4), p. 25) based on normal distributions, which I simulated with the code below and reproduced the type I error probabilities for k=1, 2, 5 and 10 of your table (k = #interim analyses). These appear to be largely independent of all three parameters used: the sample size increment n (=m in the book) and the normal distribution parameters m (=mA=mB under H0), s (=s). (Actually, it should be possible to compute these probabilities from the multivariate normal distribution of the vector (Z1, Z2, ..., ZK), but I haven't tried to do so.)

%let n=20; /* arbitrary sample size increment per group */
%let m=0;  /* arbitrary mean and */
%let s=1;  /* arbitrary std of the common normal distr. of the trt. groups A, B under H0 */

/* Simulation of the absolute value c[k] of statistic Z_k, 1<=k<=10, from Jennison/Turnbull, p. 25 */

data test(drop=j);
call streaminit(27182818);
array c[10] _temporary_;
do i=1 to 100000;
  call missing(a, b, of c[*]);
  do k=1 to 10;
    do j=1 to &n;
      a+rand('normal',&m,&s);
      b+rand('normal',&m,&s);
    end;
    c[k]=1/sqrt(2*&n*k*&s**2)*abs(a-b);
    r=(max(of c[*])>probit(0.975)); /* indicator for rejection of H0 at any stage 1, ..., k */
    output;
  end;
end;
run;

/* Computation of relative frequencies of indicator variable r
   (approximating the type I error probabilities) */

proc summary data=test nway;
class k;
var r;
output out=want(drop=_:) mean=p;
run;

proc print data=want noobs;
where k in (1, 2, 5, 10);
run;

Result:

 k       p

 1    0.05054
 2    0.08340
 5    0.14176
10    0.19369

Jennison and Turnbull cite a 1969 paper reporting 0.142 for k=5.

Jack2012
Obsidian | Level 7

Million thanks for your help. This is what I am hunting for. Thank you very much. 

sas-innovate-2024.png

Available on demand!

Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.

 

Register now!

What is ANOVA?

ANOVA, or Analysis Of Variance, is used to compare the averages or means of two or more populations to better understand how they differ. Watch this tutorial for more.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 3 replies
  • 530 views
  • 0 likes
  • 3 in conversation