approxQuantile give incorrect Median in Spark (Scala)?

后端 未结 3 757
太阳男子
太阳男子 2020-12-19 09:53

I have this test data:

 val data = List(
        List(47.5335D),
        List(67.5335D),
        List(69.5335D),
        List(444.1235D),
        List(677.53         


        
3条回答
  •  轻奢々
    轻奢々 (楼主)
    2020-12-19 10:31

    I encountered this similar problem when trying to use the approxQuantile() method with Spark-2.2.1. When I upgraded to Spark-2.4.3, approxQuantile() now returns the right exact median.

提交回复
热议问题