I have a TXT data file (file.txt
) which is formatted like so:
Column A (foo) Column B Column C
1.315116193802095950 6.564596662766380986 1.000428132834134232
...
Note that there are no tabs (all spaces), but all of the data is exactly the same column width in characters. Import["file.txt"]
just spits back the text as is (super useful, thanks Mathematica!). Import["file.txt","Data"]
will split the data line by line, but it's still just raw text within each line.
What would be great was an option that was present in good ole' Excel, which is to split the file at defined character widths. How do I get Mathematica to do this?
Import["test.txt", "Table"]
$\endgroup$Read
and friends but it is probably easier to fix the first line. $\endgroup$