# Viento: t= c( 5.3 , 5.1 , 4.8 , 4.9 , 5.3 , 5.2 , 5.5 , 5.8 , 5.6 , 5.2) ks.test(t, 'punif', min=4.7, max=5.9) # Rurales vs no rurales: r = c( 1.1 , -21.7 , -16.3 , -11.3 , -10.4 , -7 , -2 , 1.9 ,6.2) nr= c( -2.4 , 9.9 , 14.2 , 18.4 , 20.1 , 23.1 , 70.4) ks.test(r, nr) # Concentracion de hierro: x=c(49.83 , 45.08 , 49.33 , 50.47 , 51.29 , 49.85 , 51.93 , 47.24 , 45.77 , 49.89 , 49.04 , 51.23 , 52.63 , 50.22 , 49.11 , 51.22) ks.test(x, 'pnorm', 50, 2) mean(x) sd(x)^2 estandarizados = 4*(x-mean(x))/sd(x) plot(ecdf(estandarizados), main= "DistribuciĆ³n de los datos estandarizados", ylab=" ") curve(pnorm, from=-10, to=6, add=T, col="red") library("KScorrect") LcKS(estandarizados, "pnorm") # Microorganismos: t= c(0.85 ,0.70, 1.16, 3.95, 0.94, 4.04 ,0.56 ,3.93, 0.25, 1.45) ks.test(t, "pexp", 0.25) LcKS(t, "pexp")