I have a spark dataframe
spark
import pandas as pd foo = pd.DataFrame({\'id\': [1,1,2,2,2], \'col\': [\'a\',\'b\',\'a\',\'a\',\'b\'], \'value\': [1,5,2