public class MLPairRDDFunctions<K,V>
extends Object
implements scala.Serializable
Constructor and Description |
---|
MLPairRDDFunctions(RDD<scala.Tuple2<K,V>> self,
scala.reflect.ClassTag<K> evidence$1,
scala.reflect.ClassTag<V> evidence$2) |
Modifier and Type | Method and Description |
---|---|
static <K,V> MLPairRDDFunctions<K,V> |
fromPairRDD(RDD<scala.Tuple2<K,V>> rdd,
scala.reflect.ClassTag<K> evidence$3,
scala.reflect.ClassTag<V> evidence$4)
Implicit conversion from a pair RDD to MLPairRDDFunctions.
|
RDD<scala.Tuple2<K,Object>> |
topByKey(int num,
scala.math.Ordering<V> ord)
Returns the top k (largest) elements for each key from this RDD as defined by the specified
implicit Ordering[T].
|
public static <K,V> MLPairRDDFunctions<K,V> fromPairRDD(RDD<scala.Tuple2<K,V>> rdd, scala.reflect.ClassTag<K> evidence$3, scala.reflect.ClassTag<V> evidence$4)
public RDD<scala.Tuple2<K,Object>> topByKey(int num, scala.math.Ordering<V> ord)
num
- k, the number of top elements to returnord
- the implicit ordering for T