how remove from a cell array, the words in an other cell array
2 次查看(过去 30 天)
显示 更早的评论
Hi, I want to remove from the cell array word (attached), the words in an other cell array word_bis(attached). I have tried
out_str1 = strjoin(word(~ismember(word,stopwords_cellstring)),' ')
but it gives me an error:
Error using cell/ismember>cellismemberR2012a (line 193)
Input A of class cell and input B of class cell must be cell arrays of strings, unless one is a string.
Can you help me to solve the problem? thanks
0 个评论
采纳的回答
Andrei Bobrov
2017-7-18
w2 = word(cellfun(@ischar,word));
out_str1 = strjoin(w2(~ismember(w2,stopwords_cellstring)),' ');
2 个评论
Andrei Bobrov
2017-7-18
w2 = word(cellfun(@ischar,word));
out = w2(~ismember(w2,stopwords_cellstring));
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Cell Arrays 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!