def all_categories_grouping(row: pd.Series) -> str:
    '\n    Merge Category, Fuel and segment to a single string for unique categorization\n    '
    if (row['Fuel'] == 'Battery Electric'):
        return ((row['Category'] + ' / ') + row['Fuel'])
    else:
        try:
            result = ((((row['Fuel'] + ' / ') + row['Segment']) + ' / ') + row['Euro Standard'])
        except:
            result = row['Fuel']
        return result
Merge Category, Fuel and segment to a single string for unique categorization
def all_categories_grouping(row: pd.Series) -> str:
    '\n    \n    '
    if (row['Fuel'] == 'Battery Electric'):
        return ((row['Category'] + ' / ') + row['Fuel'])
    else:
        try:
            result = ((((row['Fuel'] + ' / ') + row['Segment']) + ' / ') + row['Euro Standard'])
        except:
            result = row['Fuel']
        return result