Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Python EDA Missing Values You are provided with a CSV file named sales _ data _ missing.csv containing detailed sales information. Your task is to:

Python EDA Missing Values
You are provided with a CSV file named sales_data_missing.csv containing detailed sales information. Your task is to:
Replace missing values in the promotion_id column with "No Promotion string.
Calculate the total sales for a specific product_id in a given month. Add a column for each month's total sales to the dataset. There are only two months present in the dataiorder
column for each month's total sales to the dataset. There are only two months present in the data; order these columns in ascending order by month number. If there were no sales, fill the column with '0.0'.
Ensure the final dataset contains only order_id, product_id, promotion_id, and the monthly total sales columns.
Return the cleaned dataset as a NumPy array.
Example Input:
Example Input:order_id, product_id, promotiom_id, currency, order_value, ordedate,origin, order_value_coumn1,100,, USD, 278.77,2021-01-01,0ffline, 2124.862,200, PROMO_2,,130.73,2021-01-02, Online, 4283.223,200,,112.01,112.01,2021-02-4, Direct, 1055.084,200,,112.01,112.1,2021-02-03, Direct, 1055.08
Example Output:
'No Promotion'
2124.860.0][2200 'PROMO_2'
4283.222110.16][3200'No
Promotion' 4283.222110.16]
[4200'No Promotion' 4283.22
2110.16
image text in transcribed

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Modern Database Management

Authors: Jeffrey A. Hoffer Fred R. McFadden

4th Edition

0805360476, 978-0805360479

More Books

Students also viewed these Databases questions

Question

What is the total charge of all the electrons in 1.0kg of H2O?

Answered: 1 week ago

Question

2. Define the grand narrative.

Answered: 1 week ago