Import data from txt file
Show older comments
Hi there,
my txt file looks like this: (see attached txt file)
What I try to get is a simple table with lines like this:
frame; timestamp [s]; loc_x; loc_y; loc_z
1007; 52045.728; -135.966; 225.786; -52.285
1008; 52045.745; -135.966; 225.786; -52.285
How can I do this? Thanks
3 Comments
Adam Danz
on 16 Jul 2019
I see the frame and timestamp components. Where are the xloc yloc etc.?
What are the numbers 1007; 52045.728; -135.966; 225.786; -52.285?
frame 1010 ts 52045.778 nbod 4 nfly 0 nmea 0 nmearef 0 nhand 0 nmar 0 nhuman 0 ninertial 4
bod 0 not tracked
bod 1 not tracked
bod 2 qu 1.000 loc -135.967 225.786 -52.283 rot -0.282 -0.960 0.001 0.960 -0.282 -0.008 0.008 -0.001 1.000
bod 3 not tracked
no human model data
inertial body 0 st 0 error 0.000
inertial body 1 st 0 error 0.000
inertial body 2 st 2 error 0.000
loc -135.967 225.786 -52.283 rot -0.282 -0.960 0.001 0.960 -0.282 -0.008 0.008 -0.001 1.000
inertial body 3 st 0 error 0.000
Rik
on 16 Jul 2019
Do you need code that only works on this file, or should it also handle multiple bodies being tracked?
What have you tried so far on your own?
Ferdinand Grosse-Dunker
on 16 Jul 2019
Accepted Answer
More Answers (1)
Ferdinand Grosse-Dunker
on 16 Jul 2019
0 votes
1 Comment
Adam Danz
on 16 Jul 2019
Glad I could help!
Categories
Find more on Tables in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!