nussl/evaluation/report_card.py
def _get_medians(df, decs=2):
    """
    Gets the median of each metric in the pandas
    DataFrame and returns it as a list of strings.
    """
    excluded_columns = ['source', 'file']

    metrics = [x for x in list(df.columns) if x not in excluded_columns]
    metrics.insert(0, '#')

    data = [
        f'{truncate(m, decs=decs):{4+decs}.{decs}f}' 
        for m in np.array(df.median()).T
    ]
    data.insert(0, df.shape[0])
    return metrics, data

    Gets the median of each metric in the pandas
    DataFrame and returns it as a list of strings.
    
Gets the median of each metric in the pandas
DataFrame and returns it as a list of strings.
Gets the median of each metric in the pandas DataFrame and returns it as a list of strings .
def _get_medians(df, decs=2):
    excluded_columns = ['source', 'file']
    metrics = [x for x in list(df.columns) if x not in excluded_columns]
    metrics.insert(0, '#')
    data = [
        f'{truncate(m, decs=decs):{4+decs}.{decs}f}' 
        for m in np.array(df.median()).T
    ]
    data.insert(0, df.shape[0])
    return metrics, data
def _get_medians ( df , decs = 2 ) : excluded_columns = [ 'source' , 'file' ] metrics = [ x for x in list ( df . columns ) if x not in excluded_columns ] metrics . insert ( 0 , '#' ) data = [ f'{truncate(m, decs=decs):{4+decs}.{decs}f}' for m in np . array ( df . median ( ) ) . T ] data . insert ( 0 , df . shape [ 0 ] ) return metrics , data
Gets the median of each metric in the pandas
DataFrame and returns it as a list of strings.
Gets the median of each metric in the pandas DataFrame and returns it as a list of strings .
"""
    Gets the median of each metric in the pandas
    DataFrame and returns it as a list of strings.
    """
df
decs