how to pass data of a cell to matrix??..

1 visualización (últimos 30 días)
sani ars
sani ars el 18 de Jul. de 2013
i have the code as follows:
textdata1(:,:) = textdata(:,1);
for j= 1:size(evrtng)
tkn = textdata1{j,1};
st_splt= strsplit(tkn);
= cell2mat(st_splt);
end
st_splt is a cell.... Now I don't want to have cells into cell... so that want to pass all the cells data to a matrix .... what should i write on the left side of the assignment statement of cell2mat() in the above for loop??
  1 comentario
Azzi Abdelmalek
Azzi Abdelmalek el 18 de Jul. de 2013
Editada: Azzi Abdelmalek el 18 de Jul. de 2013
Give un example of your data, when you type your variable in command windows, what do you get? what is the size of each cell?

Iniciar sesión para comentar.

Respuestas (1)

Azzi Abdelmalek
Azzi Abdelmalek el 18 de Jul. de 2013
Example
a={{1} {2} {3}}
out=horzcat(a{:})

Categorías

Más información sobre Cell Arrays en Help Center y File Exchange.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by