###BASE DE DATOS
library(tidyverse)
## Warning: package 'tidyverse' was built under R version 4.3.2
## Warning: package 'dplyr' was built under R version 4.3.2
## ── Attaching core tidyverse packages ──────────────────────── tidyverse 2.0.0 ──
## ✔ dplyr 1.1.3 ✔ readr 2.1.4
## ✔ forcats 1.0.0 ✔ stringr 1.5.0
## ✔ ggplot2 3.4.3 ✔ tibble 3.2.1
## ✔ lubridate 1.9.2 ✔ tidyr 1.3.0
## ✔ purrr 1.0.2
## ── Conflicts ────────────────────────────────────────── tidyverse_conflicts() ──
## ✖ dplyr::filter() masks stats::filter()
## ✖ dplyr::lag() masks stats::lag()
## ℹ Use the conflicted package (<http://conflicted.r-lib.org/>) to force all conflicts to become errors
##base
base_comipems <-read_csv("COMIPEMS_2023_resultados.csv")
## Rows: 23 Columns: 8
## ── Column specification ────────────────────────────────────────────────────────
## Delimiter: ","
## dbl (8): DIAGNOSTICO, DICIEMBRE, ENERO, FEBRERO, MARZO, ABRIL, MAYO, FINAL
##
## ℹ Use `spec()` to retrieve the full column specification for this data.
## ℹ Specify the column types or set `show_col_types = FALSE` to quiet this message.
base_comipems
## # A tibble: 23 × 8
## DIAGNOSTICO DICIEMBRE ENERO FEBRERO MARZO ABRIL MAYO FINAL
## <dbl> <dbl> <dbl> <dbl> <dbl> <dbl> <dbl> <dbl>
## 1 49 71 64 73 69 73 79 104
## 2 39 64 46 65 53 68 71 62
## 3 37 72 65 70 72 63 76 75
## 4 57 83 74 85 73 84 73 80
## 5 48 48 57 70 57 71 65 73
## 6 49 59 63 74 59 65 70 78
## 7 49 67 66 83 75 87 84 89
## 8 41 45 41 58 36 45 50 53
## 9 50 84 75 94 77 76 89 94
## 10 43 53 68 56 62 75 66 65
## # ℹ 13 more rows
##Estadisticas descriptivas
summary(base_comipems)
## DIAGNOSTICO DICIEMBRE ENERO FEBRERO
## Min. :30.00 Min. : 39.00 Min. :41.00 Min. :40.00
## 1st Qu.:42.00 1st Qu.: 56.50 1st Qu.:57.50 1st Qu.:67.00
## Median :49.00 Median : 66.00 Median :63.00 Median :73.00
## Mean :48.48 Mean : 66.61 Mean :63.22 Mean :73.65
## 3rd Qu.:55.50 3rd Qu.: 76.00 3rd Qu.:70.50 3rd Qu.:82.50
## Max. :68.00 Max. :104.00 Max. :91.00 Max. :98.00
## MARZO ABRIL MAYO FINAL
## Min. : 36.00 Min. : 34.00 Min. : 48.00 Min. : 53.00
## 1st Qu.: 57.00 1st Qu.: 64.50 1st Qu.: 66.00 1st Qu.: 64.00
## Median : 62.00 Median : 71.00 Median : 76.00 Median : 78.00
## Mean : 64.39 Mean : 71.22 Mean : 74.83 Mean : 79.22
## 3rd Qu.: 72.50 3rd Qu.: 82.50 3rd Qu.: 79.50 3rd Qu.: 92.00
## Max. :100.00 Max. :107.00 Max. :108.00 Max. :116.00
##Graficos de relación entre variables
plot(base_comipems$DIAGNOSTICO, base_comipems$FINAL)
plot(base_comipems$DIAGNOSTICO, base_comipems$MARZO)
plot(base_comipems$FINAL, base_comipems$ENERO)
` ```