dict1 = {i : 'control' for i in control_group} dict2 = {i : 'variant' for i in variant_group} dict_group_1 = {**dict1, **dict2}