Question: a ) Create a DataFrame df from the following dictionary: data = { 'Name': [ ' Alice ' , 'Bob', 'Charlie', 'David', 'Eva' ] ,
a Create a DataFrame df from the following dictionary:
data
'Name': Alice 'Bob', 'Charlie', 'David', 'Eva'
'Age':
'City': New York', 'Los Angeles', 'Chicago', 'Houston', 'Phoenix'
'Score':
b Display the first two rows of the DataFrame.
c Get summary statistics of the numerical columns.
d Add a new column 'Passed' to the DataFrame where the value is True if 'Score' is greater than or equal to else False.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
