def macd(df, short_long_signals=[(12, 26, 9)]):
    """
    Moving Average Convergence Divergence

    Parameters
    ----------
    df : pandas.DataFrame, must include columns ['Close']
     Dataframe where the macd is extracted from

    short_long_signals : list, default [(12, 26, 9)]
     List of periods of (short_ema, long_ema, signal) of Moving Average Convergence Divergence to be extracted

    Return
    ------
    df : pandas.DataFrame
     Dataframe with Moving Average Convergence Divergence
    """

    df = df.copy()
    for (short, long, signal) in short_long_signals:
        df[f"EMA{short}"] = df["Close"].ewm(span=short, adjust=False).mean()
        df[f"EMA{long}"] = df["Close"].ewm(span=long, adjust=False).mean()
        df[f"MACD{long}"] = df[f"EMA{short}"] - df[f"EMA{long}"]
        df[f"MACD{long}Signal"] = df[f"MACD{long}"].ewm(span=signal, adjust=False).mean()
        df = df.drop(columns=[f"EMA{short}", f"EMA{long}"])

    return df