edc question
edc question
4. Create a 3x3 NumPy array filled with random values. Then, calculate the mean, maximum, and
minimum values of the array.
5. Fit a multiple linear regression model to predict mpg using all the available predictors in the Auto
dataset. Identify significant predictors and interpret the overall model performance
SECTION B (3 x 15 = 45 Marks)
ANSWER ANY 3 OUT OF 5 QUESTIONS
6. Conduct the following basic analysis using the Auto dataset:
Find the total number of observations and variables in the dataset
Extract the 'displacement' column as a Series and display the first 10 values.
Calculate the average 'horsepower' value grouped by 'origin.'
Determine how many vehicles have a mileage above the dataset's average mileage.
Retrieve all rows where the crime rate (CRIM) exceeds 30, and display them sorted in
descending order based on crime rate
7. Create a chart for the following.
a. Donut Charts.
b. Tree Map.
c. Lollipop Charts.
d. Area Chart.
e. Bump Chart
8. Problem Statement: You have been hired as a BI Analyst by El Horno’s Pizza. The
company is trying to assess marketing strategy effectiveness and sales distribution across
different products. The Director of the company has asked you to show the following:
a. Sales trend across 2 product categories, Pizza and Burger. Build an Area Chart.
b. A Pie Chart and display Total Sales Distribution across product categories.
c. Sales distribution across product categories. Show a Chart by States which
indicates the percentage of Pizza category sales across total sales.
d. Sales distribution across product categories. Show a Chart by states which
indicates the percentage of Burger category sales across total sales.
e. Identify the States, wherein the marketing campaigns are most effective and
which of the marketing teams need to revise their tools? Show this on Vertical bar
chart.
f. A Scatter Plot and identify for correlation between Sales and Marketing Expenses,
if any. Through Highlighting feature, identify for any changes within the years.
Refer to the dataset: M3-CASE STUDY 2.csv
9. Carry out the following tasks using the Housing and Auto datasets:
a. Retrieve all rows where the AGE greater than 50, and display them in descending order.
b. Select properties located within 5 miles (DIS) of employment centers and sort them by
distance in ascending order.
c. Retrieve all properties with a pupil-teacher ratio (PTRATIO) below 15, and sort them in
ascending order by PTRATIO.
d. Retrieve all rows where the engine power (horsepower) is greater than 30, and display
them in descending order.
e. Select vehicles with 8 cylinders from the Auto dataset
10. Using the Auto dataset, perform the following visual analyses:
a. Plot a line chart to show how the horsepower of cars has changed over the model year.
What trend do you observe in the relationship between horsepower and model year?
b. Create a scatter plot to analyze the relationship between car weight and acceleration.
Does the plot suggest that heavier cars tend to have slower acceleration?
c. Generate a scatter plot of miles per gallon (mpg) versus model year, with points
differentiated by the car's origin. Analyze how fuel efficiency has evolved over time
across different regions
*****BEST WISHES*****