Question: The DataFrame dat is defined as: Name Age City State 0 Riley 1 9 Dubuque IA 1 Lex 2 5 Riverside CA 2 Mel 2

The DataFrame dat is defined as:
Name Age City State
0 Riley 19 Dubuque IA
1 Lex 25 Riverside CA
2 Mel 20 Hoboken NJ
3 Lynn 22 Austin TX
Which will return the following?
Name Age
1 Lex 25
2 Mel 20
Group of answer choices
dat.loc[2:3,['Name','Age']]
dat.loc[1:2,0:1]
dat.iloc[1:2,0:1]
dat.iloc[1:3,0:2]

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Accounting Questions!