To read a cell array
2 次查看(过去 30 天)
显示 更早的评论
回答(1 个)
Azzi Abdelmalek
2013-3-29
Example
A=num2cell(magic(5))
Col=3
A(:,col)
17 个评论
Azzi Abdelmalek
2013-3-29
编辑:Azzi Abdelmalek
2013-3-29
A=num2cell(magic(5))
t = uitable( 'Data',A)
% to read column 2
out=get(t,'Data')
col2=out(:,2)
Azzi Abdelmalek
2013-3-29
you do not need loops to access multiple columns
A=num2cell(magic(5))
col=[1 2 4]
A(:,col)
sarfudeen
2013-3-29
have 719 X 2 cell, would like to divide or multiply the 2 columns within the cells
Azzi Abdelmalek
2013-3-29
编辑:Azzi Abdelmalek
2013-3-29
A=num2cell(rand(719,2)) % Example
p=cellfun(@times,A(:,1),A(:,2))
Or use @rdivide
sarfudeen
2013-3-29
my code:
data = cellfun(@rdivide,meas(:,32),meas(:,33),'UniformOutput',false);
I have 60 numbers of columns in my "meas" file.
Azzi Abdelmalek
2013-3-29
编辑:Azzi Abdelmalek
2013-3-29
In windows command type
whos meas
what did you get?
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Develop Apps Using App Designer 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!发生错误
由于页面发生更改,无法完成操作。请重新加载页面以查看其更新后的状态。
您也可以从以下列表中选择网站:
如何获得最佳网站性能
选择中国网站(中文或英文)以获得最佳网站性能。其他 MathWorks 国家/地区网站并未针对您所在位置的访问进行优化。
美洲
- América Latina (Español)
- Canada (English)
- United States (English)
欧洲
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom(English)
亚太
- Australia (English)
- India (English)
- New Zealand (English)
- 中国
- 日本Japanese (日本語)
- 한국Korean (한국어)