Tilburg Thesis_Malawi School Dropout/src/thesis_utils_general.py
def split_features_labels_weights(df,
                                  weights=['panelweight_2016'],
                                  label_col=['dropout']):
    '''Split data into features, labels, and weights dataframes'''
    return (df.drop(weights + label_col, axis=1),
            df[label_col],
            df[weights])
Split data into features, labels, and weights dataframes
Split data into features, labels, and weights dataframes
Split data into features labels and weights dataframes
def split_features_labels_weights(df,
                                  weights=['panelweight_2016'],
                                  label_col=['dropout']):
    return (df.drop(weights + label_col, axis=1),
            df[label_col],
            df[weights])
def split_features_labels_weights ( df , weights = [ 'panelweight_2016' ] , label_col = [ 'dropout' ] ) : return ( df . drop ( weights + label_col , axis = 1 ) , df [ label_col ] , df [ weights ] )
Split data into features, labels, and weights dataframes
Split data into features labels and weights dataframes
'''Split data into features, labels, and weights dataframes'''
df
weights
label_col