You are on page 1of 16

SAS DENGAN DATA RAL DENGAN UJI T

data ransum;
input pbb kadar;
cards;
8.66 10
6.54 10
9.00 10
7.77 10
5.52 10
6.27 10
5.02 20
7.77 20
6.52 20
8.27 20
9.00 20
6.00 20
7.80 30
4.60 30
7.47 30
7.20 30
7.22 30
4.80 30
5.80 40
5.89 40
6.30 40
6.10 40
6.98 40
8.50 40
9.30 50
6.60 50
7.93 50
6.89 50
5.77 50
6.32 50
;
proc glm data=ransum;
class kadar;
model pbb=kadar;
means kadar/t;
run;

NOTE: PROCEDURE GLM used (Total process time):


real time 9:25.50
cpu time 2.62 seconds

132 data ransum;


133 input pbb kadar;
134 cards;

NOTE: The data set WORK.RANSUM has 30 observations and 2 variables.


NOTE: DATA statement used (Total process time):
real time 0.02 seconds
cpu time 0.00 seconds
165 ;
166 proc glm data=ransum;
167 class kadar;
168 model pbb=kadar;
169 means kadar/t;
170 run;

The SAS System 22:49 Thursday,


December 20, 2018 8

The GLM Procedure

Class Level Information

Class Levels Values

kadar 5 10 20 30 40 50

Number of Observations Read 30


Number of Observations Used 30

The SAS System 22:49 Thursday,


December 20, 2018 9

The GLM Procedure

Dependent Variable: pbb

Sum of
Source DF Squares Mean Square F Value
Pr > F

Model 4 2.91731333 0.72932833 0.41


0.8008

Error 25 44.63691667 1.78547667

Corrected Total 29 47.55423000

R-Square Coeff Var Root MSE pbb Mean

0.061347 19.28999 1.336217 6.927000

Source DF Type I SS Mean Square F Value


Pr > F

kadar 4 2.91731333 0.72932833 0.41


0.8008

Source DF Type III SS Mean Square F Value


Pr > F
kadar 4 2.91731333 0.72932833 0.41
0.8008

The SAS System 22:49 Thursday,


December 20, 2018 10

The GLM Procedure

t Tests (LSD) for pbb

NOTE: This test controls the Type I comparisonwise error rate, not the
experimentwise error
rate.

Alpha 0.05
Error Degrees of Freedom 25
Error Mean Square 1.785477
Critical Value of t 2.05954
Least Significant Difference 1.5889

Means with the same letter are not significantly different.

t Grouping Mean N kadar

A 7.2933 6 10
A
A 7.1350 6 50
A
A 7.0967 6 20
A
A 6.5950 6 40
A
A 6.5150 6 30

SAS DENGAN DATA RAK DENGAN UJI T


data rak;
input diameterbakteri kelompok antibiotik$;
cards;
9 1 A
6 2 A
8 3 A
9 1 B
5 2 B
8 3 B
6 1 C
7 2 C
13 3 C
8 1 D
12 2 D
11 3 D
;
proc glm data=rak;
class kelompok antibiotik;
model diameterbakteri=kelompok antibiotik;
means antibiotik/t;
run;

NOTE: PROCEDURE GLM used (Total process time):


real time 3:11.92
cpu time 1.21 seconds

213 data rak;


214 input diameterbakteri kelompok antibiotik$;
215 cards;

NOTE: The data set WORK.RAK has 12 observations and 3 variables.


NOTE: DATA statement used (Total process time):
real time 0.03 seconds
cpu time 0.01 seconds

228 ;
229 proc glm data=rak;
230 class kelompok antibiotik;
231 model diameterbakteri=kelompok antibiotik;
232 means antibiotik/t;
233 run;

NOTE: Means from the MEANS statement are not adjusted for other terms in the
model. For
adjusted means, use the LSMEANS statement.

The SAS System 22:49 Thursday,


December 20, 2018 17

The GLM Procedure

Class Level Information

Class Levels Values

kelompok 3 1 2 3

antibiotik 4 A B C D

Number of Observations Read 12


Number of Observations Used 12
The SAS System 22:49 Thursday,
December 20, 2018 18

The GLM Procedure

Dependent Variable: diameterbakteri

Sum of
Source DF Squares Mean Square F Value
Pr > F

Model 5 30.33333333 6.06666667 0.99


0.4927

Error 6 36.66666667 6.11111111

Corrected Total 11 67.00000000

R-Square Coeff Var Root MSE diameterbakteri Mean

0.452736 29.08313 2.472066 8.500000

Source DF Type I SS Mean Square F Value


Pr > F

kelompok 2 14.00000000 7.00000000 1.15


0.3790
antibiotik 3 16.33333333 5.44444444 0.89
0.4979

Source DF Type III SS Mean Square F Value


Pr > F

kelompok 2 14.00000000 7.00000000 1.15


0.3790
antibiotik 3 16.33333333 5.44444444 0.89
0.4979

The SAS System 22:49 Thursday,


December 20, 2018 19

The GLM Procedure

t Tests (LSD) for diameterbakteri

NOTE: This test controls the Type I comparisonwise error rate, not the
experimentwise error
rate.

Alpha 0.05
Error Degrees of Freedom 6
Error Mean Square 6.111111
Critical Value of t 2.44691
Least Significant Difference 4.9389
Means with the same letter are not significantly different.

t Grouping Mean N antibiotik

A 10.333 3 D
A
A 8.667 3 C
A
A 7.667 3 A
A
A 7.333 3 B

SAS DENGAN DATA RAL FAKTORIAL


data fakral;
input respons jenis_pupuk varietas_kacang;
cards;
9.99 1 1
8.68 1 2
7.45 1 3
7.39 1 1
9.67 1 2
8.58 1 3
9.01 1 1
9.68 1 2
7.53 1 3
9.00 2 1
8.41 2 2
9.46 2 3
9.57 2 1
7.49 2 2
9.60 2 3
8.61 2 1
9.52 2 2
9.00 2 3
;
proc glm data=fakral;
class jenis_pupuk varietas_kacang;
model respons=jenis_pupuk varietas_kacang jenis_pupuk*varietas_kacang;
test h=jenis_pupuk e=jenis_pupuk*varietas_kacang;
run;

NOTE: PROCEDURE GLM used (Total process time):


real time 13:55.10
cpu time 3.02 seconds

105 data fakral;


106 input respons jenis_pupuk varietas_kacang;
107 cards;

NOTE: The data set WORK.FAKRAL has 18 observations and 3 variables.


NOTE: DATA statement used (Total process time):
real time 0.32 seconds
cpu time 0.04 seconds
126 ;
127 proc glm data=fakral;
128 class jenis_pupuk varietas_kacang;
129 model respons=jenis_pupuk varietas_kacang jenis_pupuk*varietas_kacang;
130 test h=jenis_pupuk e=jenis_pupuk*varietas_kacang;
131 run;

The SAS System 22:49 Thursday,


December 20, 2018 6

The GLM Procedure

Class Level Information

Class Levels Values

jenis_pupuk 2 1 2

varietas_kacang 3 1 2 3

Number of Observations Read 18


Number of Observations Used 18

The SAS System 22:49 Thursday,


December 20, 2018 7

The GLM Procedure

Dependent Variable: respons

Sum of
Source DF Squares Mean Square F Value
Pr > F

Model 5 5.01246667 1.00249333 1.58


0.2399

Error 12 7.63333333 0.63611111

Corrected Total 17 12.64580000

R-Square Coeff Var Root MSE respons Mean

0.396374 9.049536 0.797566 8.813333

Source DF Type I SS Mean Square F Value


Pr > F

jenis_pupuk 1 0.39902222 0.39902222 0.63


0.4437
varietas_kacang 2 0.39810000 0.19905000 0.31
0.7371
jenis_pup*varietas_k 2 4.21534444 2.10767222 3.31
0.0715

Source DF Type III SS Mean Square F Value


Pr > F

jenis_pupuk 1 0.39902222 0.39902222 0.63


0.4437
varietas_kacang 2 0.39810000 0.19905000 0.31
0.7371
jenis_pup*varietas_k 2 4.21534444 2.10767222 3.31
0.0715

Tests of Hypotheses Using the Type III MS for jenis_pup*varietas_k as an


Error Term

Source DF Type III SS Mean Square F Value


Pr > F

jenis_pupuk 1 0.39902222 0.39902222 0.19


0.7059

SAS DENGAN DATA RBSL


data rbsll;
input lama metode$ perlakuan$ alat$;
datalines;
11 1 1 c
13 1 2 d
12 1 3 a
17 1 4 b
9 2 1 b
18 2 2 c
9 2 3 d
8 2 4 a
10 3 1 a
10 3 2 b
14 3 3 c
9 3 4 d
13 4 1 d
12 4 2 a
12 4 3 b
15 4 4 c
;
proc anova;
class metode perlakuan alat;
model lama=alat metode perlakuan;
means perlakuan/tukey;
run;
NOTE: PROCEDURE GLM used (Total process time):
real time 7:36.06
cpu time 2.16 seconds

234 data rbsll;


235 input lama metode$ perlakuan$ alat$;
236 datalines;

NOTE: The data set WORK.RBSLL has 16 observations and 4 variables.


NOTE: DATA statement used (Total process time):
real time 0.03 seconds
cpu time 0.03 seconds

253 ;
254 proc anova;
255 class metode perlakuan alat;
256 model lama=alat metode perlakuan;
257 means perlakuan/tukey;
258 run;

The SAS System 22:49 Thursday,


December 20, 2018 20

The ANOVA Procedure

Class Level Information

Class Levels Values

metode 4 1 2 3 4

perlakuan 4 1 2 3 4

alat 4 a b c d

Number of Observations Read 16


Number of Observations Used 16

The SAS System 22:49 Thursday,


December 20, 2018 21

The ANOVA Procedure

Dependent Variable: lama

Sum of
Source DF Squares Mean Square F Value
Pr > F

Model 9 71.5000000 7.9444444 0.84


0.6072

Error 6 56.5000000 9.4166667

Corrected Total 15 128.0000000


R-Square Coeff Var Root MSE lama Mean

0.558594 25.57216 3.068659 12.00000

Source DF Anova SS Mean Square F Value


Pr > F

alat 3 38.00000000 12.66666667 1.35


0.3454
metode 3 20.50000000 6.83333333 0.73
0.5728
perlakuan 3 13.00000000 4.33333333 0.46
0.7202

The SAS System 22:49 Thursday, December 20,


2018 22

The ANOVA Procedure

Tukey's Studentized Range (HSD) Test for lama

NOTE: This test controls the Type I experimentwise error rate, but it generally
has a higher
Type II error rate than REGWQ.

Alpha 0.05
Error Degrees of Freedom 6
Error Mean Square 9.416667
Critical Value of Studentized Range 4.89559
Minimum Significant Difference 7.5114

Means with the same letter are not significantly different.

Tukey Grouping Mean N perlakuan

A 13.250 4 2
A
A 12.250 4 4
A
A 11.750 4 3
A
A 10.750 4 1

SAS DENGAN DATA RAK FAKTORIAL


data fakrakl;
input y metode intensitas kelompok;
label y='rata-rata nilai tes';
cards;
89 1 1 1
83 1 1 2
80 1 1 3
87 1 2 1
82 1 2 2
79 1 2 3
83 1 3 1
90 1 3 2
68 1 3 3
88 2 1 1
85 2 1 2
79 2 1 3
91 2 2 1
85 2 2 2
78 2 2 3
62 2 3 1
76 2 3 2
62 2 3 3
86 3 1 1
88 3 1 2
77 3 1 3
82 3 2 1
80 3 2 2
73 3 2 3
77 3 3 1
66 3 3 2
60 3 3 3
;
proc glm data=fakrakl;
class metode intensitas kelompok;
model y=metode intensitas metode*intensitas kelompok;
lsmeans metode*intensitas/pdiff=all adjust=bon;
run;

NOTE: PROCEDURE GLM used (Total process time):


real time 4:44.18
cpu time 1.04 seconds

370 data fakrakl;


371 input y metode intensitas kelompok;
372 label y='rata-rata nilai tes';
373 cards;

NOTE: The data set WORK.FAKRAKL has 27 observations and 4 variables.


NOTE: DATA statement used (Total process time):
real time 0.06 seconds
cpu time 0.03 seconds

401 ;
402 proc glm data=fakrakl;
403 class metode intensitas kelompok;
404 model y=metode intensitas metode*intensitas kelompok;
405 lsmeans metode*intensitas/pdiff=all adjust=bon;
406 run;
The SAS System 22:49 Thursday,
December 20, 2018 23

The GLM Procedure

Class Level Information

Class Levels Values

metode 3 1 2 3

intensitas 3 1 2 3

kelompok 3 1 2 3

Number of Observations Read 27


Number of Observations Used 27

The SAS System 22:49 Thursday,


December 20, 2018 24

The GLM Procedure

Dependent Variable: y rata-rata nilai tes

Sum of
Source DF Squares Mean Square F Value
Pr > F

Model 10 1728.222222 172.822222 8.68


<.0001

Error 16 318.444444 19.902778

Corrected Total 26 2046.666667

R-Square Coeff Var Root MSE y Mean

0.844408 5.639224 4.461253 79.11111

Source DF Type I SS Mean Square F Value


Pr > F

metode 2 156.2222222 78.1111111 3.92


0.0410
intensitas 2 788.6666667 394.3333333 19.81
<.0001
metode*intensitas 4 255.1111111 63.7777778 3.20
0.0412
kelompok 2 528.2222222 264.1111111 13.27
0.0004

Source DF Type III SS Mean Square F Value


Pr > F
metode 2 156.2222222 78.1111111 3.92
0.0410
intensitas 2 788.6666667 394.3333333 19.81
<.0001
metode*intensitas 4 255.1111111 63.7777778 3.20
0.0412
kelompok 2 528.2222222 264.1111111 13.27
0.0004

The SAS System 22:49 Thursday,


December 20, 2018 25

The GLM Procedure


Least Squares Means
Adjustment for Multiple Comparisons: Bonferroni

LSMEAN
metode intensitas y LSMEAN Number

1 1 84.0000000 1
1 2 82.6666667 2
1 3 80.3333333 3
2 1 84.0000000 4
2 2 84.6666667 5
2 3 66.6666667 6
3 1 83.6666667 7
3 2 78.3333333 8
3 3 67.6666667 9

Least Squares Means for effect metode*intensitas


Pr > |t| for H0: LSMean(i)=LSMean(j)

Dependent Variable: y

i/j 1 2 3 4 5 6 7
8 9

1 1.0000 1.0000 1.0000 1.0000 0.0077 1.0000


1.0000 0.0135
2 1.0000 1.0000 1.0000 1.0000 0.0164 1.0000
1.0000 0.0290
3 1.0000 1.0000 1.0000 1.0000 0.0627 1.0000
1.0000 0.1119
4 1.0000 1.0000 1.0000 1.0000 0.0077 1.0000
1.0000 0.0135
5 1.0000 1.0000 1.0000 1.0000 0.0053 1.0000
1.0000 0.0093
6 0.0077 0.0164 0.0627 0.0077 0.0053 0.0093
0.1996 1.0000
7 1.0000 1.0000 1.0000 1.0000 1.0000 0.0093
1.0000 0.0164
8 1.0000 1.0000 1.0000 1.0000 1.0000 0.1996 1.0000
0.3544
9 0.0135 0.0290 0.1119 0.0135 0.0093 1.0000 0.0164
0.3544
SPLIT PLOT
data splitplot;
input i respons bobotbadan hijauan r;
cards;
1 82.46 1 100
2 90.37 2 100
3 89.76 3 100
4 89.35 1 110
5 76.13 2 110
6 99.78 3 110
7 95.98 1 90
8 67.65 2 90
9 89.75 3 90
10 76.34 1 120
11 91.24 2 120
12 78.67 3 120
13 73.45 1 90
14 69.23 2 90
15 83.78 3 90
16 62.98 1 110
17 78.65 2 110
18 76.54 3 110
19 90.53 1 100
20 81.26 2 100
21 66.66 3 100
22 99.23 1 120
23 89.53 2 120
24 85.54 3 120
25 92.12 1 100
26 89.32 2 100
27 85.56 3 100
28 89.75 1 120
29 76.34 2 120
30 91.24 3 120
31 78.67 1 90
32 78.67 2 90
33 73.45 3 90
34 69.23 1 110
35 78.65 2 110
36 76.54 3 110
;
procglmdata=splitplot;
class bobotbadan hijauan r;
model respons=bobotbadan r (bobotbadan) hijauan bobotbadan*hijauan;
testh=bobotbadan e=r(bobotbadan);
lsmeans bobotbadan*hijauan/pdiff=all adjust=tukey;
run;

NOTE: PROCEDURE GLM used (Total process time):


real time 1:31.22
cpu time 3.18 seconds

155 data splitplot;


156 input i respons bobotbadan hijauan r;
157 cards;

NOTE: SAS went to a new line when INPUT statement reached past the end of a line.
NOTE: The data set WORK.SPLITPLOT has 18 observations and 5 variables.
NOTE: DATA statement used (Total process time):
real time 0.03 seconds
cpu time 0.03 seconds

194 ;
195 proc glm data=splitplot;
196 class bobotbadan hijauan r;
197 model respons=bobotbadan r (bobotbadan) hijauan bobotbadan*hijauan;
198 test h=bobotbadan e=r(bobotbadan);
199 lsmeans bobotbadan*hijauan/pdiff=all adjust=tukey;
200 run;
The SAS System 16:58 Thursday,
December 19, 2018 1

The GLM Procedure

Class Level Information

Class Levels Values

bobotbadan 3 1 2 3

hijauan 4 90 100 110 120

r 18 2 4 6 8 10 12 14 16 18 20 22 24 26 28 30 32
34 36

Number of Observations Read 18


Number of Observations Used 18
The SAS System 16:58 Thursday,
December 19, 2018 2

The GLM Procedure

Dependent Variable: respons

Sum of
Source DF Squares Mean Square F Value
Pr > F

Model 17 1115.062450 65.591909 .


.

Error 0 0.000000 .

Corrected Total 17 1115.062450

R-Square Coeff Var Root MSE respons Mean

1.000000 . . 82.92833

Source DF Type I SS Mean Square F Value


Pr > F

bobotbadan 2 61.360433 30.680217 .


.
r(bobotbadan) 15 1053.702017 70.246801 .
.
hijauan 0 0.000000 . .
.
bobotbadan*hijauan 0 0.000000 . .

Source DF Type III SS Mean Square F Value


Pr > F

bobotbadan 1 49.0052083 49.0052083 .


.
r(bobotbadan) 12 907.8549333 75.6545778 .
.
hijauan 0 0.0000000 . .
.
bobotbadan*hijauan 0 0.0000000 . .
.
Tests of Hypotheses Using the Type III MS for r(bobotbadan) as an
Error Term

Source DF Type III SS Mean Square F Value


Pr > F

bobotbadan 1 49.00520833 49.00520833 0.65


0.4366

You might also like