161|PYTHON – Slice and Dice Megacorp, Inc

Kyle_Nilsen
Tue, 12 Mar 2024 03:17:42 +0000
Challenges

BYU Student Author: @Kyle_Nilsen
Reviewers: @Millie_K_B, @Trent_Barlow
Estimated Time to Solve: 45 Minutes

This is an intro challenge that is part of the Python Learning Path.

We provide the solution to this challenge using:

Python

Need a program? Click here.

Overview
You are an accounting intern for Slice and Dice MegaCorp, Inc., a newly formed yet large-scale tech corporation. The accounting department has been in shambles as a result of processing the work for various periods across the previously different companies, each with their own bookkeeping methods. At long last, they have consolidated all of the employees, products, and sales into a single excel file, “Challenge161_Data.xlsx”, though each set of info is on its own sheet. You are given the task of consolidating all sheets into one comprehensive dataset to find meaningful measures of performance for the young company and decide the most efficient way of doing this is through Python programming with the Pandas package.

Instructions
All instructions necessary for completing this challenge are contained within the provided downloadable Jupyter notebook. However, here is a summarized list of the steps you will perform:

Part I

1. Combine all sales data quarterly data into a single dataframe called data using pd.read_excel() and pd.concat(). Then load the other three Excel sheets into their own dataframes

Part II

1. Merge data and customer and find the number of customers who have not made any purchases.

2. Merge data and product and find the missing ProductID and fill in null values

3. Create and apply a function to salesperson to convert a string variable to a float, then merge it with data to find a commission calculation.

4. Perform data analysis with data manipulation and aggregate functions.

Data Files

Challenge161_SliceAndDice.ipynb

Challenge161_Data.xlsx

Suggestions and Hints (click for more details)
Solution

spoiler

2 posts - 2 participants