import pandas as pd
import pandas_profiling
import warnings
warnings.filterwarnings('ignore')
url = 'https://cloud.minsa.gob.pe/s/Y8w3wHsEdYQSZRp/download'
df = pd.read_csv(url, encoding='ISO-8859-1')
df.head()
df.shape
df.dtypes
df.DEPARTAMENTO.value_counts()
# df.DEPARTAMENTO.value_counts()['ANCASH']
df_ancash = df[df.DEPARTAMENTO == 'ANCASH']
df_ancash.reset_index(drop=True, inplace=True)
df_ancash.shape
df_ancash.FECHA_RESULTADO = pd.to_datetime(df_ancash.FECHA_RESULTADO, errors='coerce')
df_ancash.EDAD = df_ancash.EDAD.fillna(0.0).astype(int)
df_ancash.dtypes
df_ancash.drop('UUID', axis=1, inplace=True)
df_ancash.head()
df_ancash.drop('DEPARTAMENTO', axis=1, inplace=True)
df_ancash.head()
df_ancash.shape
df_ancash.dtypes
df_ancash.profile_report()