Está en la página 1de 3

PEC1 Diseño 18-19

Pregunta 1
y1. = mean(c(115,107))
y2. = mean(c(120,110))
y3. = mean(c(126,132))

y.1 = mean(c(115, 120, 126))


y.2 = mean(c(107, 110, 132))

y.. = mean(c(y1., y2., y3.))

VE1 = 2*(y1.-y..)^2+2*(y2.-y..)^2+2*(y3.-y..)^2
VE2 = 3*(y.1-y..)^2+3*(y.2-y..)^2
VT = 5*var(c(115, 120, 126, 107, 110, 132))
sr = sqrt( (VT-VE1-VE2)/(2*1) )

sr^2 * 2 / qchisq(0.95, 2)

## [1] 12.68471
sr^2 * 2 / qchisq(0.05, 2)

## [1] 740.8376

Pregunta 2
y11. = 3*102 - 104- 83.3

y11. - qt(.975, 3*2*2)*sqrt(1409/(3*2*2))/sqrt(3)

## [1] 105.0691
y11. + qt(.975, 3*2*2)*sqrt(1409/(3*2*2))/sqrt(3)

## [1] 132.3309

Pregunta 3
yi. = c(52.40, 53.06, 48.82, 46.73)

VT = 21.58*11
VNE = VT - 80.99 - 147.48

sr2 = VNE/6

num = (yi.[1] - (yi.[2]+yi.[3]) / 2)


den = sqrt( sr2*(1/3 + 1/4*( 1/3 + 1/3 )) )

num/den

1
## [1] 1.694356

Pregunta 4
VT = 80.9*(5*2*2)

VE_inter = VT - 1430.8 - 96.8 - 61

GdL_inter = (5-1)*(2-1)
GdL_inter

## [1] 4
VAR_inter = VE_inter / GdL_inter

Finter = VAR_inter / (61 / (5*2*1) )


Finter

## [1] 1.204918

Pregunta 5
ytot = (755*16+801*21)/(16+21)
VE = 16*(755-ytot)^2 + 21*(801-ytot)^2
VE

## [1] 19215.57
VNE = (16-1)*21.1^2 + (21-1)*16.3^2
VNE

## [1] 11991.95

Pregunta 6
VE_neum = 3*(6^2 +2^2 + 1^2 + 7^2)
VAR_neum = VE_neum / 3
F_neum = VAR_neum / (74 / (3*2) )
F_neum

## [1] 7.297297
qf(0.95, 3, 6)

## [1] 4.757063

Pregunta 7
Pregunta teórica.

2
Pregunta 8
LSD = qt(.975, 8*2)*sqrt(2/3)*sqrt(9.5)
LSD

## [1] 5.334978
y = c(66.7, 92.1, 75.3, 57.3, 70.7, 87.3, 60.7, 51.7)
for(i in 1:7){
for(j in (i+1):8){
if(abs(y[i]-y[j]) < LSD){
print(c(i,j))
}
}
}

## [1] 1 5
## [1] 2 6
## [1] 3 5
## [1] 4 7

También podría gustarte