Replace repeated symbol by regexprep
1 回表示 (過去 30 日間)
古いコメントを表示
Sergei Zhuravlev
2017 年 11 月 23 日
回答済み: Walter Roberson
2017 年 11 月 23 日
Hello, dear Matlab experts, I'd like to change i.e. string '1,31,' to '1,31' by using regexprep. So I need to replace second, third and others commas (or to keep only the first one). There is a plenty of characters and quantifiers for using in expression but I can not find one appropriate. I.e. I use
regexprep ('1,31,',',[1]',',')
but nothing changes.
0 件のコメント
採用された回答
その他の回答 (1 件)
参考
カテゴリ
Help Center および File Exchange で Logical についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!