MATLAB: Save all ans of for loop

save allsave for loop anssplit data

i split a text in cells into words cell1 "text" cell2 "text" cellE "text" but it gives me the last ans only how i can save all the rows
i try:
[num text data]= xlsread('result.xlsx','1') %import data from excel
[R C]=size(data);
for E=1:R % no of rows
d= regexp(data{E,6},'[ ]*','split');
end
how i can save all the answers?

Best Answer

Save ā€˜dā€™ as a cell array:
d{E} = regexp(data{E,6},'[ ]*','split');