Red neuronal con Neuralnet en R

Objetivo:

library(readr)
## Warning: package 'readr' was built under R version 4.4.3

*Paso 2: Leer el dataset

DatosTitanicEsp <- read_csv("C:/R/DatosTitanicEsp.csv")
## Rows: 891 Columns: 12
## ── Column specification ────────────────────────────────────────────────────────
## Delimiter: ","
## chr (5): Nombre, Sexo, Ticket, Cabina, Puerto
## dbl (7): Numero, Vivio, ClasePasajero, Edad, Familiares, FamiliaDirecta, Costo
## 
## ℹ 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.
View(DatosTitanicEsp)
#sumar los NA'S por cada columna factor 
sum(is.na(DatosTitanicEsp$Vivio))
## [1] 0
sum(is.na(DatosTitanicEsp$Sexo))
## [1] 0
sum(is.na(DatosTitanicEsp$Edad)) # 177 con NA'S
## [1] 177
sum(is.na(DatosTitanicEsp$ClasePasajero))
## [1] 0

Note that the echo = FALSE parameter was added to the code chunk to prevent printing of the R code that generated the plot.