How to rename columns in pandas (Python)?

0 votes

I have a DataFrame and I want to rename columns names:

Example:

["Mist","Dust","Air","Sky"]

to

["Mist1","Dust1","Air1","Sky1"]
Apr 30, 2018 in Data Analytics by DataKing99
• 8,100 points
63 views

1 answer to this question.

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.
0 votes

It is easy by just adding ".columns" attribute:

image

answered Apr 30, 2018 by DeepCoder786
• 1,700 points

Related Questions In Data Analytics

0 votes
1 answer
0 votes
1 answer

How to join two tables (tibbles) by *list* columns in R

You can use the hash from digest ...READ MORE

answered Apr 5, 2018 in Data Analytics by kappa3010
• 2,010 points
40 views
0 votes
1 answer
0 votes
1 answer

How to sort a data frame by columns in R?

You can just use the order function ...READ MORE

answered Apr 10, 2018 in Data Analytics by darklord
• 6,140 points
60 views
0 votes
1 answer

What is the Difference in Size and Count in pandas (python)?

The major difference is size includes NaN ...READ MORE

answered Apr 30, 2018 in Data Analytics by DeepCoder786
• 1,700 points
595 views
0 votes
2 answers
0 votes
1 answer

Converting a pandas data-frame to a dictionary

Emp_dict=Employee.to_dict('records') You can directly use the 'to_dict()' function ...READ MORE

answered May 23, 2018 in Data Analytics by Bharani
• 4,550 points
809 views
0 votes
1 answer

Adding values of common columns in pandas dataframe

Result = Set1.add(Set2)   x   y 0  70  ...READ MORE

answered May 30, 2018 in Data Analytics by Bharani
• 4,550 points
60 views
0 votes
7 answers
0 votes
1 answer

© 2018 Brain4ce Education Solutions Pvt. Ltd. All rights Reserved.
"PMP®","PMI®", "PMI-ACP®" and "PMBOK®" are registered marks of the Project Management Institute, Inc. MongoDB®, Mongo and the leaf logo are the registered trademarks of MongoDB, Inc.