How to accesss the columns of a matrix in a cell array in matlab?

4 vues (au cours des 30 derniers jours)
Abin Krishnan
Abin Krishnan le 15 Fév 2014
Commenté : Abin Krishnan le 15 Fév 2014
I have a cell 8X1.The elements are matrices of m-by n dimensions. I want to take the count of the elements in the nth row..
  1 commentaire
Azzi Abdelmalek
Azzi Abdelmalek le 15 Fév 2014
I want to take the count of the elements in the nth row: what does that mean?

Connectez-vous pour commenter.

Réponses (1)

Azzi Abdelmalek
Azzi Abdelmalek le 15 Fév 2014
% Example
m=4;
n=5;
A=arrayfun(@(x) rand(m,n),(1:8)','un',0)
%--------------------------------------
for k=1:numel(A)
last_row=A{k}(m,:)
%do
end

Catégories

En savoir plus sur Matrix Indexing dans Help Center et File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by