def generate_buy_signal(df, spy_large_move):
    """ Method generating a buy signal column in a given dataframe"""
    # Buy signal when SPY id having a large negative move and equity is still up
    df['Buy Signal'] = (df['SPY Change'] < spy_large_move) & (df['Change'] > 0)
    return df