ComenzarEmpieza gratis

The good old split

You have to do one last task for the obesity project. Your colleague gave you a new dataset to analyze with which you will perform the same analysis as before.

After inspecting the dataset obesity, you realize that you have the same columns as before, but the bounds column is not a list. This time, the column contains two values separated with a hyphen in the form of string.

You will process the string and then transform the column.

The DataFrame obesity is available in your session.

Este ejercicio forma parte del curso

Reshaping Data with pandas

Ver curso

Ejercicio interactivo práctico

Prueba este ejercicio y completa el código de muestra.

# Split the columns bounds using a hyphen as delimiter
obesity_split = ____[____].____.____(____)

# Print obesity_split
print(obesity_split)
Editar y ejecutar código