4

I am using koalas in databricks and trying to decile the data.

Therefore I used

df['Decile']= ks.qcut(df['Id'], q = 10, labels = False)

I am getting AttributeError: module 'databricks.koalas' has no attribute 'qcut'

Is there a work around?

Santoo
  • 355
  • 2
  • 10

1 Answers1

0

koalas does not support qcut. Though you can do it natively in PySpark, see What are alternative methods for pandas quantile and cut in pyspark 1.6.

David
  • 2,200
  • 1
  • 12
  • 22