You are now following this question
- You will see updates in your followed content feed.
- You may receive emails, depending on your communication preferences.
To read a cell array
2 views (last 30 days)
Show older comments
Answers (1)
Azzi Abdelmalek
on 29 Mar 2013
Example
A=num2cell(magic(5))
Col=3
A(:,col)
17 Comments
Azzi Abdelmalek
on 29 Mar 2013
Edited: Azzi Abdelmalek
on 29 Mar 2013
A=num2cell(magic(5))
t = uitable( 'Data',A)
% to read column 2
out=get(t,'Data')
col2=out(:,2)
Azzi Abdelmalek
on 29 Mar 2013
you do not need loops to access multiple columns
A=num2cell(magic(5))
col=[1 2 4]
A(:,col)
Azzi Abdelmalek
on 29 Mar 2013
which cell array column?
Azzi Abdelmalek
on 29 Mar 2013
p=cellfun(@times,col1,col2)
Azzi Abdelmalek
on 29 Mar 2013
Edited: Azzi Abdelmalek
on 29 Mar 2013
A=num2cell(rand(719,2)) % Example
p=cellfun(@times,A(:,1),A(:,2))
Or use @rdivide
Azzi Abdelmalek
on 29 Mar 2013
There is no error with my example, post your code
Azzi Abdelmalek
on 29 Mar 2013
meas is a cell array or a file?
Azzi Abdelmalek
on 29 Mar 2013
Edited: Azzi Abdelmalek
on 29 Mar 2013
In windows command type
whos meas
what did you get?
See Also
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!An Error Occurred
Unable to complete the action because of changes made to the page. Reload the page to see its updated state.
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
- América Latina (Español)
- Canada (English)
- United States (English)
Europe
- 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)
Asia Pacific
- Australia (English)
- India (English)
- New Zealand (English)
- 中国
- 日本Japanese (日本語)
- 한국Korean (한국어)