How to extract numbers in bracket with regex

May I know how to extract the numbers within a bracket using regex Matlab

str='eeg_eegrej( EEG, [263668 263936] )'

The expected should be

263668 , 263936

I tried as below

regexp(str, '(?<=\([[^)]*(?=\])', 'match')

but, empty return empty string



Read more here: https://stackoverflow.com/questions/68463196/how-to-extract-numbers-in-bracket-with-regex

Content Attribution

This content was originally published by balandongiv at Recent Questions - Stack Overflow, and is syndicated here via their RSS feed. You can read the original post over there.

%d bloggers like this: