def re_reference_column(df, column, index=None):
    """Re-reference a column by subtracting its value on input index."""
    if index is None:
        index = -1
    df = df.copy()

    return df[column] - df[column].iloc[index]