DP-600 · Question #41
Note: This question is part of a series of questions that present the same scenario. Each question in the series contains a unique solution that might meet the stated goals. Some question sets might h
The correct answer is B. No. The df.show() PySpark expression displays the first few rows of a DataFrame but does not calculate descriptive statistics.
Question
Note: This question is part of a series of questions that present the same scenario. Each question in the series contains a unique solution that might meet the stated goals. Some question sets might have more than one correct solution, while others might not have a correct solution. After you answer a question in this section, you will NOT be able to return to it. As a result, these questions will not appear in the review screen. You have a Fabric tenant that contains a new semantic model in OneLake. You use a Fabric notebook to read the data into a Spark DataFrame. You need to evaluate the data to calculate the min, max, mean, and standard deviation values for all the string and numeric columns. Solution: You use the following PySpark expression: df.show() Does this meet the goal?
Options
- AYes
- BNo
How the community answered
(23 responses)- A9% (2)
- B91% (21)
Why each option
The `df.show()` PySpark expression displays the first few rows of a DataFrame but does not calculate descriptive statistics.
`df.show()` is intended for data preview, not for computing statistical summaries of the entire dataset.
The `df.show()` method is used to display the content of the DataFrame in a tabular format, showing a sample of the data, and does not perform statistical aggregations like min, max, mean, or standard deviation.
Concept tested: PySpark DataFrame data preview
Source: https://spark.apache.org/docs/latest/api/python/reference/api/pyspark.sql.DataFrame.show.html
Topics
Community Discussion
No community discussion yet for this question.