Answer to Question #275544 in Python for Sonu Rathore

Question #275544

Discuss different ways of creating a dataframe in python programming




languages using panda library. Justify your answer with the help of




suitable example

1
Expert's answer
2021-12-05T13:07:42-0500

-Creating Dataframe from list of dicts

Creating a indexes DataFrame using arrays.

Example:

import pandas as pd
  
data = {'Student':['John', 'Robert', 'Lucy', 'Rachel'],
        'Scores':[100, 198, 195, 190]}

df = pd.DataFrame(data, index =['rank1', 'rank2', 'rank3','rank4'])





Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be the first!

Leave a comment

LATEST TUTORIALS
New on Blog
APPROVED BY CLIENTS