Open oldoc63 opened 2 years ago
By default, the first row of the CSV file is read in as the header row. We can use the .head() method to preview the first few rows of the DataFrame.
Sometimes columns have ambiguous or confusing names (like Census codes). We may also want to rename those columns. We can use the .columns attribute to rename the columns headings if needed:
pandas
library is designed for working with data. Start by importing the library and using the read csv() function to read de CSV data into a DataFrame object: