Value associate to a parameter in a text
1 回表示 (過去 30 日間)
古いコメントを表示
採用された回答
Paolo
2018 年 7 月 9 日
編集済み: Paolo
2018 年 7 月 9 日
data = fileread('mytextfile.txt');
val = regexp(data,'(?<=\s)(-?\d*\.?\d*)(?=\s|$)','match');
7 件のコメント
Paolo
2018 年 7 月 9 日
That's right, you will need to use the greedy * quantifier rather than the + quantifier. Since you need to match those values too, use:
(?<=KUTY01\s)-?\d*\.?\d*
I'll update my answer.
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Text Data Preparation についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!