multiplying group of columns for each unique variant in a column and fill all rows of the columns with that value

Advertisements I have a pysark DataFrame looking like that: df = spark.createDataFrame( [(0, ‘foo’), (0, ‘bar’), (0, ‘foo’), (0, np.nan), (1, ‘bar’), (1, ‘foo’), ], [‘group’, ‘value’]) df.show() Out[1]: group value 0 foo 0 bar 0 foo 0 None 1 bar 1 foo I would like to add rows for each variant of column variant… Read More multiplying group of columns for each unique variant in a column and fill all rows of the columns with that value