from pyspark.sql.types import StringType
from pyspark.sql.functions import col, collect_set, concat_ws, udf

def myFunc(data_list):
    pass
Applying UDFs on GroupedData in PySpark (with functioning python example)