Answered step by step
Verified Expert Solution
Question
1 Approved Answer
PySpark ( Python ) You are given a dataset for hard Black Friday Sales Data Set Link A. Set up your spark Environment on Colab
PySpark ( Python )
You are given a dataset for hard Black Friday Sales Data Set Link A. Set up your spark Environment on Colab and instantiate a spark object B. Write proper PySpark Code to 1. Creat appropriate Schema Structure 2. Read the CSV file as a Spark Dataframe with the correct Schema. All data needs to be in a single Spark DataFrame 3. Print the Schema of your Spark Dataframe. 4. Show the first 9 rows as a table 5. Print a statistical summary that shows the min, max, mean, and median of Purchase column. 6. How many records contains at lease one missing value. 7. Print the unique values in the Occupation column. 8. find the number of records in your spark Dataframe per unique value in the occupation column. 9. find the total Purchase per Occupation 10. order age categories by total Purchase 11. Find out if M or F in the age 1835 made more Purchase Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started