Académique Documents
Professionnel Documents
Culture Documents
ANLISIS BIVARIANTE
x1
y1
x2
y2
X1
X2
. .
XN
y1
y2
. .
YN
xN
yN
la variable X : r
la variable Y : c
Se organizan los datos en una
tabla de doble entrada
B1 B2 B3 .
Bj .
Bc
n1j .
n1c n1.
n2j .
n2c n2.
nij .
nic ni.
nrj .
nrc nr.
n.j
n.c N
3
ESTADISTICA DESCRIPTIVA
BIDIMENSIONAL
nij =
frecuencia
absoluta de
la clase
conjunta
Ai x Bj
ni. =
frecuencia
absoluta de
la clase Ai
n.j =
frecuencia
absoluta de
la clase Bj
A1
A2
.
.
.
Ai
.
.
.
Ar
B1 B2 B3 .
Bj .
Bc
n11
n21
.
.
.
ni1
.
.
.
nr1
n.1
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
n1j
n2j
.
.
.
nij
.
.
.
nrj
n.j
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
n1c
n2c
.
.
.
nic
.
.
.
nrc
n.c
n12
n22
.
.
.
ni2
.
.
.
nr2
n.2
n13
n23
.
.
.
ni3
.
.
.
nr3
n.3
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
n1.
n2.
.
.
.
ni.
.
.
.
nr.
N
4
ESTADISTICA DESCRIPTIVA
BIDIMENSIONAL
fij= nij / N
frecuencia
relativa de
la clase
conjunta
Ai x Bj
fi.= ni. / N
frecuencia
relativa de
la clase Ai
f.j= n.j / N
frecuencia
relativa de la
clase Bj
A1
A2
.
.
.
Ai
.
.
.
Ar
B1 B 2 B3 .
Bj .
Bc
f11
f21
.
.
.
fi1
.
.
.
fr1
f.1
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
f1j
f2j
.
.
.
fij
.
.
.
frj
f.j
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
f1c
f2c
.
.
.
fic
.
.
.
frc
f.c
f12
f22
.
.
.
fi2
.
.
.
fr2
f.2
f13
f23
.
.
.
fi3
.
.
.
fr3
f.3
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
f1.
f2.
.
.
.
fi.
.
.
.
fr.
1
ESTADISTICA DESCRIPTIVA
BIDIMENSIONAL
MEDIDAS DE ASOCIACIN
ENTRE VARIABLES CUANTITATIVAS
Y = Altura
x1=118
y1=64,5
x2=147
y2=65,0
x3=146
y3=69,0
x4=138
y4=64,5
x5=175
y5=66,0
x6=118
y6=64,5
66
x7=155
y7=70,5
65
x8=146
y8=66,0
64
x9=135
y9=68,0
x10=127
y10=68,5
71
70
69
Y
altura
68
67
100
110
120
130
140
150
X peso
160
170
180
Covarianza de X e Y:
x x y y x y
N
Sxy
i. i
x x y y n
x y
x y ni
i. i.
x y
Propiedades de la Covarianza:
1.
EJEMPLO:
Xi = peso
Yi = altura
(xi-
(yi - y )
(xi-
x )(yi - y
(xi- x )2
(yi -y )2
118
64,5
-22,5
-2,15
48,375
506,25
4,6225
147
65,0
6,5
-1,65
-10,725
42,25
2,7225
146
69,0
5,5
2,35
12,925
30,25
5,5225
138
64,5
-2,5
-2,15
5,375
6,25
4,6225
175
66,0
34,5
-0,65
-22,425
1190,25
0,4225
118
64,5
-22,5
-2,15
48,375
506,25
4,6225
155
70,5
14,5
3,85
55,825
210,25
14,8225
146
66,0
5,5
-0,65
-3,575
30,25
0,4225
135
68,0
-5,5
1,35
-7,425
30,25
1,8225
127
68,5
-13,5
1,85
-24,975
182,25
3,4225
1405
666,5
101,75
2734,5
43,025
x = 140,5
N=10
y = 66,65
Sxy = 10,175
Sx2 = 273,45
Sy2 = 4,30
Sx = 16,54
Sy = 2,07
10
Coeficiente de Correlacin:
x x y y / N
N
rxy
Sx.Sy
xi x yi y
Sxy 1 Sx Sy
N
Sx.Sy
N
r =1
yi= 2 + 3xi
14
10
32
35
30
25
20
15
10
5
0
0
10
15
b) r = -1
X
r = -1
10
yi= 10 2xi
12
10
8
4
2
12
X1
Y1
X2
X3
..
XN
Y2
Y3
..
YN
Sxy
Sy
2 r
Sx
Sx
a= y - b x
13
Residuo o error:
.
a)
un valor
un valor
un valor estimado
xi de la variable X
yi de la variable Y
b) Los coeficientes a y b obtenidos anteriormente son los que hacen que la suma
de los errores al cuadrado,
ei 2 , sea mnima
a)
a)
b)
Varianza residual:
Si de un individuo no tenemos ningn tipo de informacin y tratamos de predecir el
valor , y0 , que toma la variable Y en l, la mejor estimacin que podemos hacer es asignar
a y0 el valor y .
El error que cometemos viene dado por la varianza de Y, Sy2 .
Si tenemos informacin del valor que toma la variable X en ese individuo, x0 , podemos
hacer un pronstico mejor para el valor y0, asignndole el valor y0 = a + b x0. El error que
cometemos ahora ser menor, y vendr dado por lo que se conoce como varianza
14
residual. Su expresin es: SRY2 = (1-r2 ) Sy2.
X1
Y1
X2
X3
..
XN
Y2
Y3
..
YN
Sxy
Sx
r
b
Sy
Sy 2
a= x - b y
15
EJEMPLO:
Regresin de la variable altura, Y, sobre la variable peso, X, en 10 individuos.
Xi = peso
118
147
146
138
175
118
155
146
135
127
1405
Yi = altura
64,5
65,0
69,0
64,5
66,0
64,5
70,5
66,0
68,0
68,5
666,5
(xi- x )
-22,5
6,5
5,5
-2,5
34,5
-22,5
14,5
5,5
-5,5
-13,5
(yi- y )
-2,15
-1,65
2,35
-2,15
-0,65
-2,15
3,85
-0,65
1,35
1,85
y = 0,037x + 61,42
R = 0,088
(xi- x )(yi- y )
48,375
-10,725
12,925
5,375
-22,425
48,375
55,825
-3,575
-7,425
-24,975
101,75
x = 140,5
(xi- x ) 2
506,25
42,25
30,25
6,25
1190,25
506,25
210,25
30,25
30,25
182,25
2734,5
(yi- y )2
4,6225
2,7225
5,5225
4,6225
0,4225
4,6225
14,8225
0,4225
1,8225
3,4225
43,025
y = 66,65
70
Altura
Sxy = 10,175
65
Sx2 = 273,45
Sy2 = 4,30
Sx = 16,54
Sy = 2,07
125
150
Peso
175
200
16
MEDIDAS DE ASOCIACIN
ENTRE VARIABLES CUALITATIVAS
17
ESTADISTICA DESCRIPTIVA
BIDIMENSIONAL
nij =
frecuencia
absoluta de
la clase
conjunta
Ai x Bj
ni. =
frecuencia
absoluta de
la clase Ai
n.j =
frecuencia
absoluta de
la clase Bj
A1
A2
.
.
.
Ai
.
.
.
Ar
B1 B2 B3 .
Bj .
Bc
n11
n21
.
.
.
ni1
.
.
.
nr1
n.1
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
n1j
n2j
.
.
.
nij
.
.
.
nrj
n.j
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
n1c
n2c
.
.
.
nic
.
.
.
nrc
n.c
n12
n22
.
.
.
ni2
.
.
.
nr2
n.2
n13
n23
.
.
.
ni3
.
.
.
nr3
n.3
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
n1.
n2.
.
.
.
ni.
.
.
.
nr.
N
18
ESTADISTICA DESCRIPTIVA
BIDIMENSIONAL
fij= nij / N
frecuencia
relativa de
la clase
conjunta
Ai x Bj
fi.= ni. / N
frecuencia
relativa de
la clase Ai
f.j= n.j / N
frecuencia
relativa de la
clase Bj
A1
A2
.
.
.
Ai
.
.
.
Ar
B1 B 2 B3 .
Bj .
Bc
f11
f21
.
.
.
fi1
.
.
.
fr1
f.1
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
f1j
f2j
.
.
.
fij
.
.
.
frj
f.j
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
f1c
f2c
.
.
.
fic
.
.
.
frc
f.c
f12
f22
.
.
.
fi2
.
.
.
fr2
f.2
f13
f23
.
.
.
fi3
.
.
.
fr3
f.3
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
f1.
f2.
.
.
.
fi.
.
.
.
fr.
1
Medidas de asociacin:
Se trata de comparar las frecuencias observadas, nij ,
con las que se obtendran si las variables fueran
independientes : ij= ni. * n.j / N
Para ello se define la Ji- cuadrado Chi-cuadrado 2
2=
a)2 0
b)2 = 0 indica independencia de X e Y
c) Cuanto mayor es el valor de la 2 , mayor es la intensidad de la
relacin
22
d) Inconveniente: se desconoce el lmite superior del valor 2
Si
No
Hombre
Mujer
Marginal
n11= 65
n12=58
n1.=123
n21=43
n22=67 n2.=110
Margi n.1=108
nal
Hombre
n.2=125 N=233
nal
Mujer
Marginal
11= 57
12=66
n1.=123
21=51
22=59 n2.=110
Margi n.1=108
nal
Mujer
Si
No
Hombre
2=
+
n.2=125 N=233
= 4,42
23
Medidas de asociacin:
Desde un punto de vista descriptivo, para suplir el hecho de que, en
general, se desconoce el limite superior del valor de la 2, se definen
diferentes ndices de asociacin, basados en la 2 que permiten
interpretar la magnitud de los valores obtenidos:
Coeficiente Phi = =
Coeficiente V de Cramer
Coeficiente de Contingencia C de Pearson
Coeficiente Lambda
24