Staff Site Universitas Negeri Yogyakarta RANCOB DENGAN SAS

RANCANGAN PERCOBAAN DENGAN SAS

Oleh
Kismiantini, M.Si.

JURUSAN PENDIDIKAN MATEMATIKA
FAKULTAS MATEMATIKA DAN ILMU PENGETAHUAN ALAM
UNIVERSITAS NEGERI YOGYAKARTA
2010

0

SAS (Statistical Analysis System)
Berikut ini adalah window dari SAS.

Klik tombol ini untuk running program

Gambar 1. SAS window
1. Editor : digunakan untuk memasukkan data dan menganalisis data dengan perintah
tertentu. Untuk memudahkan memasukkan data, ketiklah data pada Microsoft Excell lalu
copy dan paste di Editor SAS.

2. Log : menunjukkan bahwa program dapat berjalan dengan sukses atau gagal
3. Output : hasil output yang telah di run

1

Gambar 2. Output SAS

Gambar 3. Log SAS

Bila ingin menghapus hasil output atau hasil log, pilih Edit lalu tekan Clear All.

2

RANCANGAN ACAK LENGKAP DENGAN SAS
PROGRAM
data parasetamol;
input waktu kadar;
cards;
7
40

6
40
9
40
4
40
7
40
9
50
7
50
8
50
6
50
9
50
5
60

4
60
8
60
6
60
3
60
3
75
5
75
2
75
3
75
7
75
2
90

3
90
4
90
1
90
4
90
;
proc glm data=parasetamol;
class kadar;
model waktu=kadar;
means kadar/duncan;
run;

Dapat diganti dengan mengetik t untuk
BNT dan tukey untuk BNJ

LOG
NOTE: Copyright (c) 2002-2003 by SAS Institute Inc., Cary, NC, USA.

NOTE: SAS (r) 9.1 (TS1M3)
Licensed to ACADEMIC OF INDONESIA, Site 0045663001.
NOTE: This session is executing on the XP_PRO platform.
NOTE: SAS initialization used:
real time
28.09 seconds
cpu time
1.01 seconds
1
2
3

data parasetamol;
input
waktu kadar;
cards;

NOTE: The data set WORK.PARASETAMOL has 25 observations and 2 variables.
NOTE: DATA statement used (Total process time):
real time

4.78 seconds
cpu time
0.04 seconds

3

29
30
31
32
33
34

;
proc glm data=parasetamol;
class kadar;
model waktu=kadar;
means kadar/duncan;
run;


OUTPUT
The GLM Procedure
Class Level Information
Class
kadar

Levels
5

Values
40 50 60 75 90

Number of Observations Read
Number of Observations Used

25
25

The GLM Procedure
Dependent Variable: waktu

Source
Model
Error
Corrected Total

Sum of
Squares
79.4400000
57.6000000
137.0400000

DF
4
20
24
R-Square
0.579685

Coeff Var
32.14122


Source
kadar
Source
kadar

Mean Square
19.8600000
2.8800000

Root MSE
1.697056

F Value
6.90

Pr > F
0.0012

waktu Mean

5.280000

DF
4
DF

Type I SS
79.44000000
Type III SS

Mean Square
19.86000000
Mean Square

F Value
6.90
F Value

Pr > F
0.0012

Pr > F

4

79.44000000

19.86000000

6.90

0.0012

The GLM Procedure
Duncan's Multiple Range Test for waktu
NOTE: This test controls the Type I comparisonwise error rate, not the experimentwise error rate.
Alpha
Error Degrees of Freedom
Error Mean Square
Number of Means
Critical Range

2
2.239

0.05
20
2.88

3
2.350

4
2.421

5
2.470

Means with the same letter are not significantly different.
Duncan Grouping

Mean

N

kadar

A
A
A

7.800

5

50

6.600

5

40

C
C
C

5.200

5

60

4.000

5

75

2.800

5

90

B
B
B
D
D
D

4

RANCANGAN ACAK KELOMPOK LENGKAP DENGAN SAS
PROGRAM
data rak;
input bobotbadan kelompok perlakuan$;
cards;
8
1
A
7
2
A
9
3
A
6
4
A
1
1
B
0
2
B
3
3
B
2
4
B
6
1
C
5
2
C
7
3
C
5
4
C
5
1
D
6
2
D
9
3
D
8
4
D
;
proc glm data=rak;
class kelompok perlakuan;
model bobotbadan=kelompok perlakuan;
means perlakuan/t;
run;

LOG
NOTE: PROCEDURE GLM used (Total process time):
real time
20.92 seconds
cpu time
1.04 seconds
60
61
62

data rak;
input
bobotbadan kelompok perlakuan$;
cards;

NOTE: The data set WORK.RAK has 16 observations and 3 variables.
NOTE: DATA statement used (Total process time):
real time
0.01 seconds
cpu time
0.01 seconds
79
80
81
82
83
84

;
proc glm data=rak;
class kelompok perlakuan;
model bobotbadan=kelompok perlakuan;
means perlakuan/t;
run;

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

For adjusted

OUTPUT
The GLM Procedure
Class Level Information
Class
kelompok
perlakuan

Levels
4
4

Number of Observations Read
Number of Observations Used

Values
1 2 3 4
A B C D
16
16

5

The GLM Procedure
Dependent Variable: bobotbadan
Source

DF

Sum of
Squares

Model
Error
Corrected Total

6
9
15

103.3750000
8.5625000
111.9375000

Mean Square

F Value

Pr > F

17.2291667
0.9513889

18.11

0.0001

R-Square

Coeff Var

Root MSE

bobotbadan Mean

0.923506

17.93824

0.975392

5.437500

Source
kelompok
perlakuan
Source
kelompok
perlakuan

DF

Type I SS

Mean Square

F Value

Pr > F

3
3

14.18750000
89.18750000

4.72916667
29.72916667

4.97
31.25

0.0265
F

3
3

14.18750000
89.18750000

4.72916667
29.72916667

4.97
31.25

0.0265
F

161.166667
47.916667

3.36

0.0768

R-Square

Coeff Var

Root MSE

nilai Mean

0.834580

8.762261

6.922187

79.00000

Source
waktu
matakuliah
perlakuan

DF

Anova SS

Mean Square

F Value

Pr > F

3
3
3

474.5000000
252.5000000
723.5000000

158.1666667
84.1666667
241.1666667

3.30
1.76
5.03

0.0994
0.2550
0.0446

The ANOVA Procedure
Tukey's Studentized Range (HSD) Test for nilai
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
47.91667
Critical Value of Studentized Range 4.89559
Minimum Significant Difference
16.944
Means with the same letter are not significantly different.
Tukey Grouping

Mean

N

perlakuan

A
A
A
A
A

86.250

4

A

81.250

4

B

80.500

4

D

68.000

4

C

B
B
B
B
B

8

FAKTORIAL RAL DENGAN SAS
PROGRAM
data fakral;
input
respons jenis_pupuk varietas_padi;
cards;
64
1
1
66
1
1
70
1
1
72
1
2
81
1
2
64
1
2
74
1
3
51
1
3
65
1
3
65
2
1
63
2
1
58
2
1
57
2
2
43
2
2
52
2
2
47
2
3
58
2
3
67
2
3
59
3
1
68
3
1
65
3
1
66
3
2
71
3
2
59
3
2
58
3
3
39
3
3
42
3
3
58
4
1
41
4
1
46
4
1
57
4
2
61
4
2
53
4
2
53
4
3
59
4
3
38
4
3
;
proc glm data=fakral;
class jenis_pupuk varietas_padi;
model respons=jenis_pupuk varietas_padi jenis_pupuk*varietas_padi;
test h=jenis_pupuk e=jenis_pupuk*varietas_padi;
run;

LOG
NOTE: PROCEDURE ANOVA used (Total process time):
real time
8:21.67
cpu time
3.00 seconds

144
145
146

data fakral;
input
respons jenis_pupuk varietas_padi;
cards;

NOTE: SAS went to a new line when INPUT statement reached past the end of a line.
NOTE: The data set WORK.FAKRAL has 36 observations and 3 variables.

9

NOTE: DATA statement used (Total process time):
real time
0.04 seconds
cpu time
0.00 seconds
184
185
186
187
188
189

;
proc glm data=fakral;
class jenis_pupuk varietas_padi;
model respons=jenis_pupuk varietas_padi jenis_pupuk*varietas_padi;
test h=jenis_pupuk e=jenis_pupuk*varietas_padi;
run;

OUTPUT
The GLM Procedure
Class Level Information
Class

Levels

jenis_pupuk
varietas_padi

Values

4
3

1 2 3 4
1 2 3

Number of Observations Read
Number of Observations Used

36
36

The GLM Procedure
Dependent Variable: respons
Source

DF

Sum of
Squares

Model
Error
Corrected Total

11
24
35

2277.222222
1501.333333
3778.555556

R-Square
0.602670
Source
jenis_pupuk
varietas_padi
jenis_pup*varietas_p

Source
jenis_pupuk
varietas_padi
jenis_pup*varietas_p

Coeff Var
13.49438

Mean Square

F Value

Pr > F

207.020202
62.555556

3.31

0.0069

Root MSE
7.909207

respons Mean
58.61111

DF

Type I SS

Mean Square

F Value

Pr > F

3
2
6

1156.555556
349.388889
771.277778

385.518519
174.694444
128.546296

6.16
2.79
2.05

0.0029
0.0812
0.0971

DF

Type III SS

Mean Square

F Value

Pr > F

3
2
6

1156.555556
349.388889
771.277778

385.518519
174.694444
128.546296

6.16
2.79
2.05

0.0029
0.0812
0.0971

Tests of Hypotheses Using the Type III MS for jenis_pup*varietas_p as an Error Term
Source
jenis_pupuk

DF

Type III SS

Mean Square

F Value

Pr > F

3

1156.555556

385.518519

3.00

0.1170

10

PROGRAM
data fakral;
input respons lama dosis;
cards;
96
2
0
98
2
0
94
2
0
90
4
0
94
4
0
92
4
0
92
2
16
88
2
16
90
2
16
88
4
16
92
4
16
94
4
16
92
2
32
94
2
32
84
2
32
78
4
32
82
4
32
74
4
32
74
2
48
74
2
48
68
2
48
0
4
48
0
4
48
0
4
48
50
2
64
50
2
64
54
2
64
0
4
64
0
4
64
0
4
64
;
proc glm data=fakral;
class lama dosis;
model respons=lama dosis lama*dosis;
lsmeans lama*dosis / pdiff=all adjust=tukey;
run;

Dapat diganti dengan bon,
dunnet, scheffe, sidak

LOG
NOTE: PROCEDURE GLM used (Total process time):
real time
23.17 seconds
cpu time
1.32 seconds
1124
1125
1126

data fakral;
input respons lama dosis;
cards;

NOTE: The data set WORK.FAKRAL has 30 observations and 3 variables.
NOTE: DATA statement used (Total process time):
real time
0.04 seconds
cpu time
0.01 seconds
1157
1158
1159
1160
1161
1162

;
proc glm data=fakral;
class lama dosis;
model respons=lama dosis lama*dosis;
lsmeans lama*dosis / pdiff=all adjust=tukey;
run;

11

OUTPUT
The GLM Procedure
Class Level Information
Class

Levels

lama
dosis

2
5

Values
2 4
0 16 32 48 64

Number of Observations Read
Number of Observations Used

30
30

The GLM Procedure
Dependent Variable: respons
Source

DF

Sum of
Squares

Model
Error
Corrected Total

9
20
29

37430.53333
165.33333
37595.86667

Source
lama
dosis
lama*dosis
Source
lama
dosis
lama*dosis

Mean Square

F Value

Pr > F

4158.94815
8.26667

503.10

F

1
4
4

5713.20000
25459.20000
6258.13333

5713.20000
6364.80000
1564.53333

691.11
769.94
189.26