plot cell arrays...

조회 수: 154 (최근 30일)
KSSV
KSSV 2012년 2월 6일
답변: Jy Lee 2022년 5월 31일
Hi all
How to plot the data which is in cell arrays? When I use plot I get the following error.
"Conversion to double from cell is not possible"
Thanks in advance
Sreenu

채택된 답변

Walter Roberson
Walter Roberson 2012년 2월 6일
You cannot plot data that is in cell arrays. Extract the data from the cell arrays and plot that. For example,
plot(MyCell{2,5}, MyCell{3,7})
  댓글 수: 3
Logabharathi Aruchamy
Logabharathi Aruchamy 2012년 4월 11일
It helped me a lot. thanks a lot Walter!
PRASHANT TIWARI
PRASHANT TIWARI 2022년 3월 5일
편집: PRASHANT TIWARI 2022년 3월 5일
What if they are in loop.
Stress{i} = [Stress_local{i}(1,1)]
Strain{i} = [Strain_local{i}(1,1)]
on plotting it shows only last ith point.

댓글을 달려면 로그인하십시오.

추가 답변 (2개)

Jorge Alliende
Jorge Alliende 2014년 3월 28일
편집: Jorge Alliende 2014년 3월 28일
You can plot your cell data in this way:
figure;
hold on;
cellfun(@plot,MyCell);
Best
Jorge
  댓글 수: 1
PRASHANT TIWARI
PRASHANT TIWARI 2022년 3월 5일
Stress_local{i}(1,1)
Strain_local{i}(1,1)
how to plot for Stress_local{i}(1,1) vs Strain_local{i}(1,1) for each i value not only last value.

댓글을 달려면 로그인하십시오.


Jy Lee
Jy Lee 2022년 5월 31일
Everyone, understand question?

카테고리

Help CenterFile Exchange에서 Annotations에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by