Remove parentheses with regexp
17 visualizzazioni (ultimi 30 giorni)
Mostra commenti meno recenti
Giorgos Papakonstantinou
il 14 Gen 2014
Commentato: Giorgos Papakonstantinou
il 14 Gen 2014
I have the following string:
a ='0.00 (578)';
How can I use regexp to retrieve what is inside the parentheses?
I have used this
regexp('0.00 (578)', '\S*\s', 'match')
but it gives me:
'0.00 '
0 Commenti
Risposta accettata
Azzi Abdelmalek
il 14 Gen 2014
Modificato: Azzi Abdelmalek
il 14 Gen 2014
a ='0.00 (578)';
regexp(a,'(?<=\()[\d.]+(?=\))','match')
Più risposte (0)
Vedere anche
Categorie
Scopri di più su Characters and Strings in Help Center e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!