How to delete the first line in txt file?

37 次查看(过去 30 天)
Hi! I saw that there are already some solutions here, but none of them worked for me. I would like to remove first line from the txt files. Here is an example:
Year Month Day Value
2014 12 1 0
2014 12 2 0
2014 12 3 0
2014 12 4 0
2014 12 5 0.2
2014 12 6 0
2014 12 7 0
2014 12 8 0
2014 12 9 0
2014 12 10 0
2014 12 11 0
2014 12 12 0
2014 12 13 0
2014 12 14 0
2014 12 15 0
2014 12 16 0
2014 12 17 0

采纳的回答

Star Strider
Star Strider 2020-5-17
The readtable function willl create VariableNames from the first line.
For most of the other functions (such as textscan) use the name-value pair 'HeaderLines',1 to skip the first line.

更多回答(0 个)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by