I have this prbolem, I have one of this kind RDD[(String, Array[String]), and I would like extract from it a RDD[Array[String]] that contains the values grouped by key:
e.g:
val x :RDD[(String, Array[String]) =
RDD[(a, Array[ "ra", "re", "ri"]),
(a, Array[ "ta", "te", "ti"]),
(b, Array[ "pa", "pe", "pi"])]
I would like get:
val result: RDD[(String, RDD[Array[String]]) =
RDD[(a, RDD[Array[("ra", "re", "ri"),( "ta", "te", "ti")]]),
(b, RDD[Array[("pa", "pe", "pi"),...]])
,...]