library (ggplot2)
library ("easypackages")
clean_calcium = read.csv ("clean_calcium.csv")
str (clean_calcium)
## 'data.frame': 178 obs. of 8 variables:
## $ Observacion: int 1 2 3 4 5 6 7 8 9 10 ...
## $ Age : int 78 72 72 73 73 73 65 68 89 84 ...
## $ Sex : chr "Female" "Female" "Female" "Female" ...
## $ ALP : num 83 117 132 102 114 ...
## $ Lab : chr "CB Rouche" "CB Rouche" "CB Rouche" "CB Rouche" ...
## $ CaMol : num 2.53 2.5 2.43 2.48 2.33 2.13 2.55 2.45 2.25 2.43 ...
## $ PhoMol : num 1.07 1.16 1.13 0.81 1.13 0.84 1.26 1.23 0.65 0.84 ...
## $ AgeG : chr "75 - 79 years" "70 - 74 years" "70 - 74 years" "70 - 74 years" ...
Distribución de los pacientes por edad, laboratorio y Sexo
boxplot (clean_calcium $ Age, main = "Distruibución de los pacientes por Edad", col = "blue", ylab = "Edad")
barplot (table (clean_calcium $ Lab), main = "Distruibución de los pacientes por Laboratorio", col = c ("blue", "red", "green"), xlab = "Laboratorio", ylab = "Cantidad")
barplot (table (clean_calcium $ Sex), main = "Distruibución de los pacientes por Sexo", col = c ("blue", "red"), xlab = "Sexo", ylab = "Cantidad")
Diferencias de las variables clínicas: ALP, CaMol, PhoMol entre los grupos de edad (AgeG), Sexo (Sex) y Laboratorio (Lab)
boxplot (clean_calcium $ ALP ~ clean_calcium $ AgeG, main = "Distruibución de la Variable clinica ALP entre el grupo Edad", cex.names = 0.8, col = rep (c ("blue")), ylab = "ALP", xlab = "Edad (AgeG)")
boxplot (clean_calcium $ ALP ~ clean_calcium $ Sex, main = "Distruibución de la Variable clinica ALP entre el grupo Sexo", cex.names = 0.8, col = rep (c ("blue")), ylab = "ALP", xlab = "Sexo (Sex)")
boxplot (clean_calcium $ ALP ~ clean_calcium $ Lab, main = "Distruibución de la Variable clinica ALP entre el grupo Laboratorio", cex.names = 0.8, col = rep (c ("blue")), ylab = "ALP", xlab = "Laboratorio (Lab)")
boxplot (clean_calcium $ CaMol ~ clean_calcium $ AgeG, main = "Distruibución de la Variable clinica CaMol entre el grupo Edad", cex.names = 0.8, col = rep (c ("blue")), ylab = "CaMol", xlab = "Edad (AgeG)")
boxplot (clean_calcium $ CaMol ~ clean_calcium $ Sex, main = "Distruibución de la Variable clinica CaMol entre el grupo Sexo", cex.names = 0.8, col = rep (c ("blue")), ylab = "CaMol", xlab = "Sexo (Sex)")
boxplot (clean_calcium $ CaMol ~ clean_calcium $ Lab, main = "Distruibución de la Variable clinica CaMol entre el grupo Laboratorio", cex.names = 0.8, col = rep (c ("blue")), ylab = "CaMol", xlab = "Laboratorio (Lab)")
boxplot (clean_calcium $ PhoMol ~ clean_calcium $ AgeG, main = "Distruibución de la Variable clinica PhoMol entre el grupo Edad", cex.names = 0.8, col = rep (c ("blue")), ylab = "PhoMol", xlab = "Edad (AgeG)")
boxplot (clean_calcium $ PhoMol ~ clean_calcium $ Sex, main = "Distruibución de la Variable clinica PhoMol entre el grupo Sexo", cex.names = 0.8, col = rep (c ("blue")), ylab = "PhoMol", xlab = "Sexo (Sex)")
boxplot (clean_calcium $ PhoMol ~ clean_calcium $ Lab, main = "Distruibución de la Variable clinica PhoMol entre el grupo Laboratorio", cex.names = 0.8, col = rep (c ("blue")), ylab = "PhoMol", xlab = "Laboratorio (Lab)")
La estructura de correlación entre las variables cuantitativas: Age, ALP, CaMol, PhoMol
clean_calcium.cor = cor (clean_calcium [, c (2, 4, 6, 7)], method = "pearson")
corrplot :: corrplot (clean_calcium.cor , method = "ellipse", addCoef.col = "black", type = "upper")
pairs (clean_calcium [, c (2, 4, 6, 7)], lower.panel = panel.smooth, pch = 15)