def concatenate_misses(df, subject):
    """
    Concatenates for each subject all hithistory variables (true/false),
    which describe the success of the trial.

    Parameters
    ----------
    df : dataframe
        data
    subject: str
        subject chosen

    Returns
    -------
    Performance of each subject by trials

    """
    df_hh = df[['misshistory', 'subject_name']]
    # make a group for each subjects
    df_grps = df_hh.groupby('subject_name')
    # obtain the performance for each subject
    df_sbj_perf = df_grps.get_group(subject)['misshistory'].values
    return df_sbj_perf