CSV: Create New Headerline
Ältere Kommentare anzeigen
In a CSV file, I would like to replace (delete) a headerline, first line, and create a new headerline. So the CSV file is (for this example I applied extra spaces to make it more readable):
State, Tornado, Hurricane, Earthquake,
Texas, 34, 5, 0,
Indiana, 8, 0, 2,
California, 2, 2, 20,
North Carolina, 1, 10, 1,
So now I need to delete the first headerline and replace it with a new headerline -- ST TOR HUR EAR -- see below:
ST, TOR, HUR, EAR,
Texas, 34, 5, 0,
Indiana, 8, 0, 2,
California, 2, 2, 20,
North Carolina, 1, 10, 1,
Thanks,
Amanda
2 Kommentare
Cedric
am 6 Mai 2013
I still don't know whether there are commas in your CSV file or if the content is really like what is written in your question (?)
Akzeptierte Antwort
Weitere Antworten (0)
Kategorien
Mehr zu Oil, Gas & Petrochemical finden Sie in Hilfe-Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!