DataFrame.
foreachPartition
Applies the f function to each partition of this DataFrame.
f
DataFrame
This a shorthand for df.rdd.foreachPartition().
df.rdd.foreachPartition()
New in version 1.3.0.
Examples
>>> def f(people): ... for person in people: ... print(person.name) >>> df.foreachPartition(f)