sebaba/utils.py
def missing_var_pct(df = None):
    """
    Function that return variables that have missing values and the percentage 
    of total observations that are missing
    
    Parameters:
    --------------------------------------------------
        df: DataFrame
    
    Returns:
    --------------------------------------------------
        missing : Pandas Series with variables and their respective missing percentages
    """
    pct_missing  = df.isnull().mean().sort_values(ascending = False) * 100
    pct_missing  = pct_missing.loc[pct_missing > 0].round(2)
    
    if len(pct_missing) > 0:
        print(f"{pct_missing}")
    else:
        print("The dataframe has no missing values in any column.")

    Function that return variables that have missing values and the percentage 
    of total observations that are missing
    
    Parameters:
    --------------------------------------------------
        df: DataFrame
    
    Returns:
    --------------------------------------------------
        missing : Pandas Series with variables and their respective missing percentages
    
Function that return variables that have missing values and the percentage
of total observations that are missing
Function that return variables that have missing values and the percentage of total observations that are missing
def missing_var_pct(df = None):
    pct_missing  = df.isnull().mean().sort_values(ascending = False) * 100
    pct_missing  = pct_missing.loc[pct_missing > 0].round(2)
    if len(pct_missing) > 0:
        print(f"{pct_missing}")
    else:
        print("The dataframe has no missing values in any column.")
def missing_var_pct ( df = None ) : pct_missing = df . isnull ( ) . mean ( ) . sort_values ( ascending = False ) * 100 pct_missing = pct_missing . loc [ pct_missing > 0 ] . round ( 2 ) if len ( pct_missing ) > 0 : print ( f"{pct_missing}" ) else : print ( "The dataframe has no missing values in any column." )
Function that return variables that have missing values and the percentage
of total observations that are missing
Function that return variables that have missing values and the percentage of total observations that are missing
"""
    Function that return variables that have missing values and the percentage 
    of total observations that are missing
    
    Parameters:
    --------------------------------------------------
        df: DataFrame
    
    Returns:
    --------------------------------------------------
        missing : Pandas Series with variables and their respective missing percentages
    """
missing : Pandas Series with variables and their respective missing percentages
missing : Pandas Series with variables and their respective missing percentages
df
None