I have a csv file with a lot of data I am looking to edit. I have a column (DJ in excel) that I need to multiply the numbers in the cells by 1.12. I was wondering how I could do that as I have 3800 rows in that single column. Would I have to read the current csv and write it onto a new csv?
This is the code I think I need to enter:
#skip header
next(reader, None)
#print new header
writer.writerow(['Data'])
for row in reader:
newVal = float(row[0]) * 1.12
writer.writerow([newVal])
Not sure how to change the values in the column.