def enumerate_col(input_df, enumerate_over, new_col="newCol"):
    """
    Enumerate unique entries in enumerate_over_col and add new column newCol.
    """
    new_df = input_df.copy()
    unique_vals = new_df[enumerate_over].unique()
    enumerated_dict = {vals: ix for ix, vals in enumerate(unique_vals)}
    new_df.loc[:, new_col] = new_df[enumerate_over].map(lambda x: enumerated_dict[x])
    return new_df