Professional Documents
Culture Documents
4.- ADDITIVITY
Block by litter/location/plot/lab
ALTERNATIVE?
Assign and compare treatments
within BLOCKS
after
Animal before
after
70
115
100
178
84
148
110
179
88
176
67
140
110
191
79
161
105
158
10
86
157
PAIRED SAMPLES
Calculate the difference (X1 X2) by pairs of
values and use a test t to check if it differs
from zero:
SAS proc:
Data explosio;
Input animal before after;
Dif=after-before;
proc means n mean var std stderr t prt;
var before after dif;
proc print;
run;
PAIRED SAMPLES
N Obs
Variable
Mean
Variance
Std Dev
Std Error
10
BEFORE
10
89.90
247.88
15.74
4.98
AFTER
10
160.30
498.23
22.32
7.06
DIF
10
70.40
179.16
13.38
4.23
N Obs
Variable
Prob<|T|
10
BEFORE
18.06
0.001
AFTER
22.71
0.0001
DIF
16.63
0.0001
(Mead y Curnow)
BINOMIAL DISTRIBUTION
Comparison of proportions.
Values of dependent variables= 0 1.
Illness incidence, fertility, mortality.
Probability of successes out of total
number of observations.
Normal vs. X2 distribution.
Binomial distribution:
IC95% ( x
n 1, 0.025
n 1, 0.975
ANALYSIS OF PROPORTIONS:
USING A NORMAL DISTRIBUTION (N>50)
F
NF
%F
FEED 1
80
20
100
80
FEED 2
175
25
200
87.5
TOTAL
255
45
300
85
2
d
0.00215
NF
%F
FEED 1
80
20
100
80
FEED 2
175
25
200
87.5
TOTAL
255
45
300
85
OBS.
EXP.
DESV.
P1-F
80
85
-5
P1-NF
20
15
+5
P2-F
175
170
+5
P2-NF
25
30
-5
X 2 52 1 / 85 1 / 15 1 / 170 1 / 30 2.94
X 2 (1 d.f.; 5%) 3.84 A 5% of the values in the distribution are 3.84
2.94 3.84 NS at 5%
Hoja excel
BINOMIAL DISTRIBUTION
Degrees of
freedom
50
10
2.5
0.1
0.45
2.71
3.84
5.02
6.64
10.8
1.39
4.61
5.99
7.38
9.21
13.8
2.37
6.25
7.82
9.35
11.3
16.3
3.36
7.78
9.49
11.1
13.3
18.5
4.35
9.24
11.1
12.8
15.1
20.5
5.35
10.6
12.6
14.5
16.8
22.5
6.35
12.0
14.1
16.0
18.5
24.3
7.34
13.4
15.5
17.5
20.1
26.1
8.34
14.7
16.9
19.0
21.7
27.9
10
9.34
16.0
18.3
20.5
23.2
29.6
12
11.3
18.5
21.0
23.3
26.2
32.9
15
14.3
22.3
25.0
27.5
30.6
37.7
20
19.3
28.4
31.4
34.2
37.6
45.3
24
23.3
33.2
36.4
39.4
43.0
51.2
30
29.3
40.3
43.8
47
50.9
59.7
40
39.3
51.8
55.8
59.3
63.7
73.4
60
59.3
74.4
79.1
83.3
88.4
99.6
SAS ORDERS
Data valor z;
Z=probit (1-/2);run;
Data valor f;
F=finv(1- , gl1, gl2);run;
Data valor t;
t= tinv (1- /2, n-1);
Data valor chi;
Chi=probchi (x2, gl);run;
Proc print;
Run;
ANALYSIS OF PROPORTIONS
2 VS T
Prop P1
Prop P2
X2
P X2
P t test
10
0.3
0.4
0.22
0.639
0.66
30
0.1
0.2
1.18
0.278
0.286
30
0.3
0.4
0.66
0.417
0.426
30
0.52
0.6
0.33
0.568
0.578
50
0.1
0.2
1.96
0.161
0.165
50
0.2
0.3
1.33
0.248
0.2526
100
0.2
0.3
2.67
0.102
0.103
100
0.5
0.6
2.02
0.155
0.157
Pienso
A
A
B
B
destete
21
28
21
28
lechones incidencia
960
42
878
15
780
62
945
25
Parmetro
Intercept
pienso
a
pienso
b
destete
21
destete
28
pienso*destete
pienso*destete
pienso*destete
pienso*destete
a
a
b
b
1
1
0
1
0
21
28
21
28
Fuente
pienso
1
destete
1
pienso*destete 1
7.74
29.81
0.23
0.0054
<.0001
0.6283
Efecto
Error
Chipienso destete Estimador estndar
pienso
a
pienso
b
destete
destete
pienso*destete
pienso*destete
pienso*destete
pienso*destete
a
a
b
b
21
28
21
28
21
28
-3.5684
-3.0274
-2.7669
-3.8289
-3.0845
-4.0524
-2.4493
-3.6055
0.1523
0.1210
0.1030
0.1650
0.1578
0.2604
0.1324
0.2027
1
1
1
1
1
1
1
1
549.32
625.52
721.90
538.44
382.12
242.12
342.39
316.39
<.0001
<.0001
<.0001
<.0001
<.0001
<.0001
<.0001
<.0001
[i/(1- i)]-trat 1
= e1.156 = 3.18
Odd ratio=
[i/(1- i)]-trat 2
Source
glm
genmod
tb
BF
BF*BF
BW
Pariteit
Batch
Treatment
DF
Type I SS
Mean Square
F Value
Pr > F
1
1
1
1
4
3
2
0.11962043
0.01411844
0.02726153
0.03406395
0.01666229
0.01904203
0.00434103
0.11962043
0.01411844
0.02726153
0.03406395
0.00416557
0.00634734
0.00217051
13.10
1.55
2.98
3.73
0.46
0.69
0.24
0.0005
0.2173
0.0878
0.0569
0.7677
0.5577
0.7890
Source
Deviance
DF
ChiSquare
Pr > ChiSq
Intercept
tb
BF
BF*BF
BW
Pariteit
Batch
Treatment
166.0464
146.6630
145.0037
140.2808
134.2984
131.2930
128.8061
127.7296
1
1
1
1
4
3
2
19.38
1.66
4.72
5.98
3.01
2.49
1.08
<.0001
0.1977
0.0298
0.0144
0.5569
0.4777
0.5838
1.- INDEPENDENCE
2.- NORMALITY
3.- VARIANCE HOMOGENEITY
Variable transformations
4.- ADDITIVITY
Treatments affect mean values but should not affect to its variability
VARIANCE HETEROGENEITY:
START
FNWT
VARIANCE HOMOGENEITY
Levenes test
Proc glm data=veneer;
class brand;
Model wear=brand;
Means brand/hovtest;
Run;
Source
DF
SUM OF SQUARES
MEAN SQUARE
F VALUE
Pr>F
Model
0.61700000
0.15425000
7.40
0.0017
Error
15
0.31250000
0.02033333
Corrected total
19
0.92950000
R-Square
Coeff Var
Root MSE
Wear Mean
0.663798
Source
6.155120
DF
0.144338
TYPE III SS
2.345000
MEAN SQUARE
F VALUE
Pr>F
0.61700000
0.15425000
7.40
0.0017
brand
Levenes test for homogeneity of wear variance ANOVA of squared deviations from group means
Source
brand
Error
DF
4
15
SUM OF SQUARE
0.000659
0.00466
MEAN SQUARE
0.000165
0.000310
F VALUE
0.93
NS = variance homogeneous
Pr>F
0.7149
MEAN
RANGE
RANGE/MEAN
RANGE/ MEAN
413
223
0.54
11.0
395
123
0.31
6.2
87
102
1.17
10.9
79
70
0.89
7.9
38
71
1.87
11.5
35
59
1.67
10.0
If range values are similar and are not related to meansDO NOT TRANSFORM
If range/means are similarTRANSF. LOGARITHM
If range/means are similarTRANSF. ROOT SQUARE
ADDITIVITY
Treatment effects should be about the same in different blocks,
e.g. insect traps placed in different locations, micro counts
Serie 1
Serie 2
Serie 3
Control
2
10
100
Logarithm scale
Serie 1
Serie 2
Serie 3
Trtmt
4
20
200
Control
0.301
1
2
Differ.
2
10
100
Trtmt
0.602
1.301
2.301
Differ.
0.301
0.301
0.301
ADDITIVITY
INSECT COUNTING
UNTRANSFORMED
LOG COUNTS
TRAP TYPE
SITE 1
A
B
11
13
47
62
105
170
1.04
1.11
1.67
1.79
2.02
2.23
15
87
165
1.18
1.94
2.22
43
86
0.85
1.63
1.93