Tutorial-2 PySpark mapPartitions,filter transformation
Here we are going to discuss mapPartitions ,mapPartitionsWithIndex and filter operation. (a) MapPartitions: This transformation is similar to map,but runs separately on each partition (block) of the RDD. MapPartitions can be used as an alternative to map and foreach. Q-1 Remove the specific number from input list or input RDD using mapPartitions Read more…