lisa.datautils.df_merge#
- lisa.datautils.df_merge(df_list, drop_columns=None, drop_inplace=False, filter_columns=None)[source]#
Merge a list of
pandas.DataFrame
, keeping the index sorted.- Parameters:
drop_columns (list(str)) – List of columns to drop prior to merging. This avoids ending up with extra renamed columns if some dataframes have column names in common.
drop_inplace (bool) – Drop columns in the original dataframes instead of creating copies.
filter_columns (dict(str, object)) – Dict of {“column”: value) used to filter each dataframe prior to dropping columns. The columns are then dropped as they have a constant value.