CAFE

Multiple Comparisons: ANOVA and ANCOVA

작성자안재형|작성시간09.12.23|조회수1,290 목록 댓글 0

 

첨부파일 bpr.csv 

첨부파일 PlantGrowth.csv

 

### ANOVA

proc import datafile="u:\data\data\plantgrowth.csv" out=plantgrowth dbms=csv replace; run;

 

## Dunnett

proc mixed data=plantgrowth;
  class group;
  model weight = group;
  lsmeans group / adjust=dunnett pdiff=control("ctrl");
run;

                                              Differences of Least Squares Means

                                                               Standard
          Effect    group     _group    Estimate       Error      DF    t Value    Pr > |t|    Adjustment       Adj P

          group     trt1          ctrl       -0.3710        0.2788      27      -1.33      0.1944      Dunnett           0.3227
          group     trt2          ctrl        0.4940         0.2788      27       1.77      0.0877      Dunnett           0.1535

 

## Tukey

proc mixed data=plantgrowth;
  class group;
  model weight = group;
  lsmeans group / adjust=tukey pdiff;
run;

                                              Differences of Least Squares Means

                                                                Standard
          Effect    group     _group    Estimate      Error      DF    t Value    Pr > |t|  Adjustment       Adj P

          group     ctrl         trt1        0.3710        0.2788      27       1.33       0.1944     Tukey            0.3909
          group     ctrl         trt2       -0.4940        0.2788      27      -1.77      0.0877     Tukey            0.1980
          group     trt1         trt2       -0.8650        0.2788      27      -3.10      0.0045     Tukey            0.0120

 

### ANCOVA

proc import datafile="u:\data\data\bpr.csv" out=bpr dbms=csv replace; run;

 

## Dunnett-Hsi

proc mixed data=bpr;
  class therapy;
  model dbp10=therapy dbp7 sbp7;
  lsmeans therapy / adjust=dunnett pdiff;
run;

                                             Differences of Least Squares Means

                                                                        Standard
        Effect     THERAPY    _THERAPY    Estimate     Error      DF    t Value    Pr > |t|   Adjustment      Adj P

        THERAPY    Dose 1     Placeb       -2.5363      1.3281     170      -1.91      0.0579    Dunnett-Hsu     0.1407
        THERAPY    Dose 2     Placeb       -5.3689      1.2975     170      -4.14      <.0001    Dunnett-Hsu     0.0002
        THERAPY    Dose 3     Placeb       -3.8647      1.3624     170      -2.84      0.0051    Dunnett-Hsu     0.0140

 

## Tukey-Kramer

proc mixed data=bpr;
  class therapy;
  model dbp10=therapy dbp7 sbp7;
  lsmeans therapy / adjust=tukey pdiff;
run; 

                                              Differences of Least Squares Means

                                                      Standard
        Effect     THERAPY    _THERAPY    Estimate       Error      DF    t Value    Pr > |t|    Adjustment       Adj P

        THERAPY    Dose 1     Dose 2        2.8327      1.2557     170       2.26       0.0254    Tukey-Kramer    0.1127
        THERAPY    Dose 1     Dose 3        1.3285      1.3214     170       1.01       0.3162    Tukey-Kramer    0.7465
        THERAPY    Dose 1     Placeb       -2.5363      1.3281     170      -1.91      0.0579    Tukey-Kramer    0.2278
        THERAPY    Dose 2     Dose 3       -1.5042      1.2884     170      -1.17      0.2446    Tukey-Kramer    0.6481
        THERAPY    Dose 2     Placeb       -5.3689      1.2975     170      -4.14      <.0001    Tukey-Kramer    0.0003
        THERAPY    Dose 3     Placeb       -3.8647      1.3624     170      -2.84      0.0051    Tukey-Kramer    0.0261

 

## Exact method

# Dunnett
proc mixed data=bpr;
  class therapy;
  model dbp10=therapy dbp7 sbp7;
  lsmeans therapy / pdiff=control("Placeb") cl adjust=simulate(nsamp=10000000 cvadjust seed=121011 report);
run; 

                                            Differences of Least Squares Means

                                                          Standard
   Effect   THERAPY  _THERAPY  Estimate  Error    DF  t Value  Pr > |t|  Adjustment  Adj P   Alpha     Lower     Upper

   THERAPY  Dose 1   Placeb     -2.5363    1.3281   170    -1.91    0.0579  Simulate      0.1407    0.05   -5.1579   0.08536
   THERAPY  Dose 2   Placeb     -5.3689    1.2975   170    -4.14    <.0001  Simulate      0.0002    0.05   -7.9301   -2.8077
   THERAPY  Dose 3   Placeb     -3.8647    1.3624   170    -2.84    0.0051  Simulate      0.0140    0.05   -6.5541   -1.1754

                                            Differences of Least Squares Means

                                                                        Adj         Adj
                                       Effect   THERAPY  _THERAPY     Lower       Upper

                                       THERAPY  Dose 1   Placeb     -5.6759      0.6034
                                       THERAPY  Dose 2   Placeb     -8.4362     -2.3016
                                       THERAPY  Dose 3   Placeb     -7.0855     -0.6440

 

# Tukey
proc mixed data=bpr;
  class therapy;
  model dbp10=therapy dbp7 sbp7;
  lsmeans therapy / pdiff cl adjust=simulate(nsamp=10000000 cvadjust seed=121011 report);
run;

                                            Differences of Least Squares Means

                                         Standard
   Effect   THERAPY  _THERAPY  Estimate  Error   DF  t Value  Pr > |t|  Adjustment   Adj P   Alpha     Lower     Upper

   THERAPY  Dose 1   Dose 2      2.8327    1.2557   170     2.26    0.0254   Simulate      0.1126    0.05    0.3539    5.3114
   THERAPY  Dose 1   Dose 3      1.3285    1.3214   170     1.01    0.3162   Simulate      0.7463    0.05   -1.2801    3.9370
   THERAPY  Dose 1   Placeb     -2.5363    1.3281   170    -1.91    0.0579  Simulate      0.2276    0.05   -5.1579   0.08536
   THERAPY  Dose 2   Dose 3     -1.5042    1.2884   170    -1.17    0.2446  Simulate      0.6480    0.05   -4.0474    1.0391
   THERAPY  Dose 2   Placeb     -5.3689    1.2975   170    -4.14    <.0001  Simulate     0.0003    0.05   -7.9301   -2.8077
   THERAPY  Dose 3   Placeb     -3.8647    1.3624   170    -2.84    0.0051   Simulate     0.0260    0.05   -6.5541   -1.1754

 

                                            Differences of Least Squares Means

                                                                        Adj         Adj
                                       Effect   THERAPY  _THERAPY     Lower       Upper

                                       THERAPY  Dose 1   Dose 2     -0.4248      6.0901
                                       THERAPY  Dose 1   Dose 3     -2.0996      4.7565
                                       THERAPY  Dose 1   Placeb     -5.9815      0.9089
                                       THERAPY  Dose 2   Dose 3     -4.8464      1.8380
                                       THERAPY  Dose 2   Placeb     -8.7347     -2.0031
                                       THERAPY  Dose 3   Placeb     -7.3990     -0.3305

 

 

 

다음검색
현재 게시글 추가 기능 열기

댓글

댓글 리스트
맨위로

카페 검색

카페 검색어 입력폼