How to scan a user-input sentence/phrase for the individual words
古いコメントを表示
I'm writing a text to speech program in the Malay Language for a project. I have created a GUI with an editbox for the user-input. For starters, how do I scan the user-input sentence for words?
Using these words, I will match them with their corresponding *.wav file from a database of Malay words (Malay is written with English alphabets too)
採用された回答
その他の回答 (1 件)
Chaowei Chen
2011 年 8 月 27 日
0 投票
Just a subtle improvement to Jiang's approach. (To get rid of the period symbol)
InputText='This is is my testing speech.';
Words2=regexp(InputText,'\w*','match')
1 件のコメント
Fangjun Jiang
2011 年 8 月 27 日
Agree! There are many other things to be taken care of too, like InputText='This''s my testing speech.'.
カテゴリ
ヘルプ センター および File Exchange で Simulation, Tuning, and Visualization についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!