
Ultimate access to all questions.
You are working on a machine learning project in Spark and need to apply a custom transformation to a Pandas DataFrame within a Pandas UDF. Explain the steps you would take to implement this transformation and provide an example of how you would apply it.
A
Define a Pandas UDF that takes the Pandas DataFrame as input, applies the custom transformation, and returns the transformed DataFrame.
B
Use the Pandas UDF to apply the custom transformation to each row of the Pandas DataFrame individually.
C
Use the Pandas UDF to apply the custom transformation to the entire Pandas DataFrame at once, without considering any row-specific differences.
D
Use the Pandas UDF to apply the custom transformation to a subset of the Pandas DataFrame, ignoring the rest of the data.