南方醫(yī)科大學生物統(tǒng)計學系(510515)
高培純 徐笑寒 徐 瑩 陳平雁△
1.2.2.8 基于均差高階交叉設(shè)計的等效性檢驗
Schuirmann’s(1987)[1],Phillip(1990)[2]和Chen(1997)[3]給出的高階交叉設(shè)計的樣本量估計方法是建立在近似服從自由度為vk的t分布上,其檢驗效能的計算公式為:
(1-55)
在計算樣本量時,一般先設(shè)定樣本量初始值,然后迭代樣本量直到所得的檢驗效能滿足條件為止。此時的樣本量,即研究所需的樣本量。
①4×2設(shè)計(Balaam's design),v1=4n-3,b1=2
②2×3設(shè)計(the two-sequence dual design),v2=4n-4,b2=3/4
④4×4設(shè)計(the four-period with four sequences),v4=12n-5,b4=1/4
【例1-29】欲比較兩種降壓藥物對舒張壓的降壓效果。根據(jù)以往研究,患者使用對照藥后平均舒張壓為96mmHg,研究者認為使用新藥后患者平均舒張壓能降到92mmHg。已知均方誤為324。新藥均值與對照藥均值差值置信區(qū)間在對照藥均值±20%之內(nèi)可認為兩種藥物等效,本研究等效性界值設(shè)定為-19.2和19.2。試驗設(shè)計采用2×3設(shè)計,檢驗水準為0.05,欲估計檢驗效能為90%的樣本量。
nQuery Advanced 8.2 實現(xiàn):設(shè)定檢驗水準為α=0.05,檢驗效能取90%。由題意知,μ2-μ1=-4,LEL=-19.2,UEL=19.2,Sw=18。在nQuery Advanced 8.2主菜單選擇:
Goal:Make conclusion Using:⊙Means
Number of Groups:⊙Two
Analysis Method:⊙Equivalence
方法框中選擇:Higher-order Cross-Over Design for Two Means- Equivalence-using Differences
在彈出的樣本量計算窗口將各參數(shù)鍵入,如圖1-69所示,結(jié)果為N=20。
圖1-69 nQuery Advanced 8.2 關(guān)于例1-29樣本量估計的參數(shù)設(shè)置與計算結(jié)果
SAS 9.4軟件實現(xiàn):
proc IML;
start MTE51(Designtype,a,Delta,UEL,LEL,Sw,power);
error=0;
if(Designtype=1|Designtype=2|Designtype=3|Designtype=4)then do;
error=0;end;
else do;error=1;print"error" "Designtype must be 1 or 2 or 3 or 4";end;
if( a>0.2 | a<0) then do;
error=1;print"error" "Test significance level must be in 0-0.2";end;
if( Delta>UEL | Delta error=1;print"error" "True difference in means set between upper and lower limits";end; if(UEL<0 ) then do; error=1;print"error" "Upper equivalence limit difference must be>0 ";end; if(LEL>0 ) then do; error=1;print"error" "Lower equivalence limit difference must be<0 ";end; if(Sw<0) then do; error=1;print"error" "Within standard error must be>=0"; end; if(power>100 | power<1) then do; error=1;print"error" "Power(%) must be in 1-100";end; if(error=1) then stop; if(error=0) then do; if(Designtype=1) then do;n=1;b=2;end; if(Designtype=2) then do;n=2;b=3/4;end; if(Designtype=3) then do;n=1;b=11/20;end; if(Designtype=4) then do;n=1;b=1/4;end; do until(pw>=power/100); if(Designtype=1) then do;df=4*n-3;end; if(Designtype=2) then do;df=4*n-4;end; if(Designtype=3) then do;df=6*n-5;end; if(Designtype=4) then do;df=12*n-5;end; tU=(-Delta+UEL)/(Sw*sqrt(b/n))-tinv(1-a,df); tL=tinv(1-a,df)-(Delta-LEL)/(Sw*sqrt(b/n)); pw1=1-probt(tU,df); pw2=1-probt(tL,df); pw=pw2-pw1;n=n+0.01; end; if(Designtype=1) then do;N=ceil((n-0.01)*4);end; if(Designtype=2) then do;N=ceil((n-0.01)*2);end; if(Designtype=3) then do;N=ceil((n-0.01)*2);end; if(Designtype=4) then do;N=ceil((n-0.01)*4);end; if(Designtype=1) then do;Design_type="1. 4*2";end; if(Designtype=2) then do;Design_type="2. 2*3";end; if(Designtype=3) then do;Design_type="3. 2*4";end; if(Designtype=4) then do;Design_type="4. 4*4";end; print Design_type a[label="Test Significance Level"] Delta[label="True Difference in Means.u2-u1"] LEL[label="Lower Equivalence Limit"] UEL[label="Upper Equivalence Limit"] Sw[label="Within Standard Error(Sw)"] power[label="Power(%)"] N[label="N"];end; finish MTE51; run MTE51(2,0.05,-4,19.2,-19.2,18,90); quit; SAS 9.4運行結(jié)果: 圖1-70 SAS 9.4關(guān)于例1-29樣本量估計的參數(shù)設(shè)置與計算結(jié)果 1.2.2.9 基于比值高階交叉設(shè)計的等效性檢驗 Schuirmann’s (1987)[1],Phillip(1990)[2]和Chen(1997)[3]給出的高階交叉設(shè)計的樣本量估計方法是建立在近似服從自由度為vk的t分布上,其檢驗效能的計算公式為: (1-56) 在計算樣本量時,一般先設(shè)定樣本量初始值,然后迭代樣本量直到所得的檢驗效能滿足條件為止。此時的樣本量,即研究所需的樣本量。 【例1-30】某公司欲驗證新開工廠生產(chǎn)的藥物與舊工廠生產(chǎn)的藥物是否等效。根據(jù)以往研究數(shù)據(jù),舊工廠生產(chǎn)藥物CV為0.4。假定新舊工廠生產(chǎn)藥物均值比值為0.96。根據(jù)指導原則,新工廠生產(chǎn)的藥物與舊工廠生產(chǎn)的藥物的均值比不低于0.8且不高于1.25可認為等效。若采用2×3設(shè)計,試估計檢驗效能為90%的樣本量。 nQuery Advanced 8.2實現(xiàn):設(shè)定檢驗水準為α=0.05,檢驗效能取90%。由題意知,μ2/μ1=0.96,LER=0.8,UER=1.25,CV=0.4。在nQuery Advanced 8.2主菜單選擇: 方法框中選擇:Higher-order Cross-Over Design for Two Means- Equivalence-using Ratio 在彈出的樣本量計算窗口將各參數(shù)鍵入,如圖1-71所示,結(jié)果為N=60。 圖1-71 nQuery Advanced 8.2 關(guān)于例1-30樣本量估計的參數(shù)設(shè)置與計算結(jié)果 SAS9.4軟件實現(xiàn): proc IML; start MTE81(Designtype,a,Ratio,UER,LER,CV,power); error=0; if(Designtype=1|Designtype=2|Designtype=3|Designtype=4)then do; error=0;end; else do; error=1;print"error" "Designtype must be 1 or 2 or 3 or 4";end; if( a>0.2 | a<0) then do; error=1;print"error" "Test significance level must be in 0-0.2";end; if( Ratio>UER | Ratio error=1;print"error" "True ratio of means set between upper and lower equivalence ratio limits";end; if( UER<1 ) then do; error=1;print"error" "Upper equivalence limit ratio must be>= 1";end; if( LER>= 1 | LER<= 0) then do; error=1;print"error" "Lower equivalence limit ratio must be in 0-1";end; if( Ratio>UER | Ratio error=1;print"error" "Ture ratio must be set between Upper and Lower equivalence ratio limit";end; if( CV<0) then do; error=1;print"error" "Coefficient of variance must be>= 0";end; if(power>100 | power<1) then do; error=1;print"error" "Power(%) must be in 1 - 100";end; if(error=1) then stop; if(error=0) then do; if(Designtype=1) then do;n=1;b=2;end; if(Designtype=2) then do;n=2;b=3/4;end; if(Designtype=3) then do;n=1;b=11/20;end; if(Designtype=4) then do;n=1;b=1/4;end; CVm=sqrt(log(CV**2+1)); do until(pw>=power/100); if(Designtype=1) then do;df=4*n-3;end; if(Designtype=2) then do;df=4*n-4;end; if(Designtype=3) then do;df=6*n-5;end; if(Designtype=4) then do;df=12*n-5;end; tU=(-abs(log(Ratio))+log(UER))/(CVm*sqrt(b/n))-tinv(1-a,df); tL=tinv(1-a,df)-(abs(log(Ratio))-log(LER))/(CVm*sqrt(b/n)); pw1=1-probt(tU,df); pw2=1-probt(tL,df); pw=pw2-pw1;n=n+0.01; end; if(Designtype=1) then do;N=ceil((n-0.01)*4);end; if(Designtype=2) then do;N=ceil((n-0.01)*2);end; if(Designtype=3) then do;N=ceil((n-0.01)*2);end; if(Designtype=4) then do;N=ceil((n-0.01)*4);end; if(Designtype=1) then do;Design_Type="1.4*2";end; if(Designtype=2) then do;Design_Type="2.2*3";end; if(Designtype=3) then do;Design_Type="3.2*4";end; if(Designtype=4) then do;Design_Type="4.4*4";end; print Design_Type a[label="Test Significance Level"] Ratio[label="True Ratio of Means,u2/u1"] LER[label="Lower Equivalence Ratio"] UER[label="Upper Equivalence Ratio"] CV[label="Coefficient of Variance(non-logarithmic),CV"] power[label="Power(%)"] N[label="N"];end; finish MTE81; run MTE81(2,0.05,0.96,1.25,0.8,0.4,90); quit; SAS運行結(jié)果; 圖1-72 SAS 9.4 關(guān)于例1-30樣本量估計的參數(shù)設(shè)置與計算結(jié)果 1.2.2.10 基于均差高階交叉設(shè)計的非劣效性檢驗 Chen(1997)[3]和Chow and Liu (2009)[4]給出的高階交叉設(shè)計的樣本量估計方法是建立在近似服從自由度為vk的t分布上,當指標為高優(yōu)指標時,其檢驗效能計算公式為: (1-57) 當指標為低優(yōu)指標時,對應(yīng)的檢驗效能計算公式為: (1-58) 在計算樣本量時,一般先設(shè)定樣本量初始值,然后迭代樣本量直到所得的檢驗效能滿足條件為止。此時的樣本量,即研究所需的樣本量。 【例1-31】某公司欲驗證一種治療風濕病的仿制藥非劣于標準藥,擬采用2×3設(shè)計。研究者決定將非劣界值設(shè)置為-5。根據(jù)以往類似研究,已知均方誤為100。假設(shè)仿制藥與標準藥真實差值為0。檢驗水準設(shè)置為0.05,試估計檢驗效能為90%所需的樣本量。 nQuery Advanced 8.2 實現(xiàn):設(shè)定檢驗水準為α=0.05,檢驗效能取90%。由題意知,μ2-μ1=0,NIM=-5,Sw=10。在nQuery Advanced 8.2主菜單選擇: 方法框中選擇:Higher-order Cross-Over Design for Two Means- Non-Inferiority-using Differences 在彈出的樣本量計算窗口將各參數(shù)鍵入,如圖1-73所示,結(jié)果為N=53。 圖1-73 nQuery Advanced 8.2 關(guān)于例1-31樣本量估計的參數(shù)設(shè)置與計算結(jié)果 SAS 9.4軟件實現(xiàn): proc IML; start MTE61(Designtype,Better,a,Delta,NIM,Sw,power); error=0; if(Designtype=1|Designtype=2|Designtype=3|Designtype=4)then do; error=0;end; else do; error=1;print"error" "Designtype must be 1 or 2 or 3 or 4";end; if( a>0.2 | a<0) then do; error=1;print"error" "Test significance level must be in 0-0.2";end; if( Better=1 | Better=0)then do; error=0;end; else do; error=1;print"error" "Higher means better(1)/worse(0)";end; if( Better=1 ) then do; if( Delta<= -abs(NIM))then do; error=1;print"error" "True difference in means must>Non-Inferiority margin if higher means better";end; end; if( Better=0 ) then do; if( Delta>= abs(NIM) )then do; error=1;print"error" "True difference in means must end; if(Sw<0) then do; error=1;print"error" "Within standard error must be>=0";end; if(power>100 | power<1) then do; error=1;print"error" "Power(%) must be in 1-100";end; if(error=1) then stop; if(error=0) then do; if(Designtype=1) then do;n=1;b=2;end; if(Designtype=2) then do;n=2;b=3/4;end; if(Designtype=3) then do;n=1;b=11/20;end; if(Designtype=4) then do;n=1;b=1/4;end; if(Better=1) then do; do until(pw>=power/100); if(Designtype=1) then do;df=4*n-3;end; if(Designtype=2) then do;df=4*n-4;end; if(Designtype=3) then do;df=6*n-5;end; if(Designtype=4) then do;df=12*n-5;end; t=(Delta+abs(NIM))/(Sw*sqrt(b/n))-tinv(1-a,df); pw=probt(t,df);n=n+0.01; end; end; if(Better=0) then do; do until(pw>=power/100); if(Designtype=1) then do;df=4*n-3;end; if(Designtype=2) then do;df=4*n-4;end; if(Designtype=3) then do;df=6*n-5;end; if(Designtype=4) then do;df=12*n-5;end; t=tinv(1-a,df)-(-Delta+abs(NIM))/(Sw*sqrt(b/n)); pw=probt(t,df);n=n+0.01; end; end; if(Designtype=1) then do;N=ceil((n-0.01)*4);end; if(Designtype=2) then do;N=ceil((n-0.01)*2);end; if(Designtype=3) then do;N=ceil((n-0.01)*2);end; if(Designtype=4) then do;N=ceil((n-0.01)*4);end; if(Designtype=1) then do;Design_type="1. 4*2";end; if(Designtype=2) then do;Design_type="2. 2*3";end; if(Designtype=3) then do;Design_type="3. 2*4";end; if(Designtype=4) then do;Design_type="4. 4*4";end; if better=1 then Better_="better";else Better_="worse"; print Design_type Better_[label="Higher Mean Values are"] a[label="Test Significance Level"] Delta[label="True Difference in Means.u2-u1"] NIM[label="Non-Inferiority Margin"] Sw[label="Within Standard Error"] power[label="Power(%)"] N[label="N"]; end; finish MTE61; run MTE61(2,1,0.05,0,-5,10,90); quit; SAS運行結(jié)果: 圖1-74 SAS 9.4 關(guān)于例1-31樣本量估計的參數(shù)設(shè)置與計算結(jié)果