PANDAS HW Due Wed May 5th 1) Import pandas as pd a. Create a series of 5 dog names b. Create a series of 5 dog’s ages c. Create a data frame that has dog names as the index and two columns of data....

1 answer below »
Complete in Python follow directions



PANDAS HW Due Wed May 5th 1) Import pandas as pd a. Create a series of 5 dog names b. Create a series of 5 dog’s ages c. Create a data frame that has dog names as the index and two columns of data. First column is the age, and second column is “yes” or “no” for being adopted. d. Locate the data for each dog e. Locate all adopted dogs 2) Create a data frame with 5 athletes include columns and data for win percentage, age, and sport (two athletes should play the same sport for this - problem). Make sure to populate your data frame with data. a. Locate each athlete’s data b. Locate athlete’s data that play the same sport 3) Create a data frame with your choice of index, columns, and data. a. There should be at least 3 data columns in your data frame. b. Locate two different indexes in your data frame.
Answered Same DayMay 05, 2021

Answer To: PANDAS HW Due Wed May 5th 1) Import pandas as pd a. Create a series of 5 dog names b. Create a...

Gaurav answered on May 06 2021
152 Votes
import pandas as pd
Dgnames = ["Tommy", "Shero", "vinee", "jackie", "facebook"]
Dgage = [12, 11, 4
, 7, 3]
dgdic = {"age": Dgage, "names" : Dgnames, "isAdopted": ["yes", "no", "yes", "yes", "no"]}
df = pd.DataFrame(dgdic)
df.set_index("names", inplace=True)
#getting info for each dog
for...
SOLUTION.PDF

Answer To This Question Is Available To Download

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here