How to convert cell to matrix

1 回表示 (過去 30 日間)
Shahar ben ezra
Shahar ben ezra 2021 年 3 月 2 日
コメント済み: Shahar ben ezra 2021 年 3 月 2 日
hi
How to convert cell to matrix in this situation
t= readtable('loopTest');
for i=1:3
new_matrix{i}=t(:,i*3);
end
new_matrix=cell2mat(new_matrix) % this is not work:(
new_matrix=mean(new_matrix)
It is important for me to use the readtable function and not readmatrix
If I did this in the readmatrix function I would get a matrix of 16 * 3
This is what I want only with function"readtable"

採用された回答

Walter Roberson
Walter Roberson 2021 年 3 月 2 日
new_matrix{i}=t{:,i*3};
  1 件のコメント
Shahar ben ezra
Shahar ben ezra 2021 年 3 月 2 日
TNX!

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeCell Arrays についてさらに検索

製品


リリース

R2019b

Community Treasure Hunt

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

Start Hunting!

Translated by