0

I have created a Spark DataFrame, using python, and I want to get a mapping for the categorical variables. In other words, I would like to achieve the same results as if I run df['name-of-variable'].cat.codes on python pandas. Is there a way to achieve this?

Dimitris Poulopoulos
  • 1,139
  • 2
  • 15
  • 36

0 Answers0