# create list and enter header values header_list = ["Val1", "Val2", "Val3"] # create a dataframe ex: df and tell pandas to read in your csv # in same line assign your list to the names= df = pd.read_csv("sample_file.csv", names=header_list)
Here is what the above code is Doing:
1. Creating a list called header_list
2. Creating a dataframe called df
3. Telling pandas to read in your csv
4. Assigning your list to the names=