フィルターのクリア

Cell contents assignment to a non-cell array object, hdf data

2 ビュー (過去 30 日間)
Emma
Emma 2012 年 10 月 24 日
I have data in the form of an hdf file that I would like to fit into a 2400x2400x46 matrix. Currently when I read-in the hdf data, the result is in the form of a 1x46 cell array (each cell containing a 2400x2400 matrix). I also get the error message 'Cell contents assignment to a non-cell array object.' How might I make this cell array fit into the 2400x2400x46 matrix format?

回答 (1 件)

Matt Fig
Matt Fig 2012 年 10 月 24 日
編集済み: Matt Fig 2012 年 10 月 24 日
Just access each element of the cell array whenever you need to access one of the arrays,
C{1} = magic(3); % Sample cell array
C{2} = rand(2);
C{2}(2,2) % Access the element (2,2) of the 2-by-2 rand array
C{1}(3) % Access the third element in the magic matrix.

カテゴリ

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

Community Treasure Hunt

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

Start Hunting!

Translated by