def aggregate_fields(df, list_of_fields, separator, agg_field_name):
    """ Join multiple columns of a dataframe into a single column.

    Args:
        df (pandas df)
        list_of_fields (list of strings): columns from df to aggregate
        separator (string): string separator to use in the aggregation
        agg_field_name (string): what to name the new, aggregated column

    Returns:
        df (pandas df): same as input, but one new column appended

    """
    # Check that each field to aggregate is present
    for f in list_of_fields:
        assert f in df.columns, (
            "{} is not present as a metadata field.".format(f))

    sub_df = df[list_of_fields]

    agg_col = []
    for _, my_series in sub_df.iterrows():
        agg_col.append(my_series.astype(str).str.cat(sep=separator))

    df[agg_field_name] = agg_col

    return df