title: Oversampling or SMOTE in Pyspark
body: <p>I have 7 classes and the total number of records are 115 and I wanted to run Random Forest model over this data. But as the data is not enough to get a high accuracy. So i wanted to apply oversampling over all the classes in a way that the majority class itself get higher count and then minority accordingly. Is this possible in PySpark?</p>
  
  <pre><code>+---------+-----+
  | SubTribe|count|
  +---------+-----+
  |    Chill|   10|
  |     Cool|   18|
  |Adventure|   18|
  |    Quirk|   13|
  |  Mystery|   25|
  |    Party|   18|
  |Glamorous|   13|
  +---------+-----+
  </code></pre>