QuestionQ153

Prepare data

You have a Fabric tenant that contains a new semantic model in OneLake.

You use a Fabric notebook to load the data into a Spark DataFrame.

You need to evaluate the data to calculate the minimum, maximum, mean, and standard deviation values for all string and numeric columns.

Solution: You use the following PySpark expression:

df.show()  

Does this achieve the goal?

  • A Yes
  • B No
Explanation

DataFrame.show() prints the first rows of a DataFrame for inspection; it does not compute minimum, maximum, mean, or standard deviation for its columns. Statistical aggregation or a summary operation is required to produce those values.

Learn more

Community Discussion

No comments yet. Be the first to start the discussion!