I have a sample data which I would like to do the PySpark version of str.get_dummies but am not sure how to do it.
title_df:
Film Category
LOTR Drama, Fantasy
STAR WARS Sci-Fi, Action
etc.
Which will then give me with:
Film Action Fantasy Drama Sci-Fi Romance Comedy
LOTR 0 1 1 0 0 0
STAR WARS 1 0 0 1 0 0
etc.
Appreciate the help!