Loading data from document and isolating numbers.
1 view (last 30 days)
Show older comments
Hi, I have to add to creating program a complicated database from other file with united numbers sometimes with no space between them. Which formula should I use to load from random line in data document, and isolate them to other calculations.
Example 1.543 345.1200 1.32399.0099.00 1.3399.00
Thank you.
Accepted Answer
Walter Roberson
on 9 Jan 2013
NumericLine = str2double( regexp( regexprep(TheLine, '99\.0', ' &'), '\s+', 'split') );
2 Comments
Walter Roberson
on 10 Jan 2013
You would need to have scanned the line as a string, so you might as well fgetl() instead of fscanf()
More Answers (0)
See Also
Categories
Find more on Database Toolbox 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!