필터 지우기
필터 지우기

Place two 3d plots in the same grid so they can be compared

조회 수: 1 (최근 30일)
stefano lazzeri
stefano lazzeri 2023년 2월 28일
댓글: stefano lazzeri 2023년 3월 3일
Kmatc0 is: 501 x 15
Kmatc1 is: 501 x 15
vc0_cp1 is: 501 x 15
figure(1)
cs1 = mesh(log(Kmatc0),log(Zmatc0),vc0_cp1)
hold on
cs1
cs2 = mesh(log(Kmatc0),log(Zmatc0),vc0_cp0)
hold off
When I run this it does not give me two, but only one of them.
I would like them both to appear in only one grid.
Thank you in advance for your help.
Best

채택된 답변

Luca Ferro
Luca Ferro 2023년 2월 28일
편집: Luca Ferro 2023년 2월 28일
Supposing that the mesh function is called properly, the syntax seems alright, have you though that they may be coincident?
log(Kmatc0),log(Zmatc0) are the same for both meshes and since you didn't share any actual values it's impossible to tell if vc0_cp1 and vc0_cp0 are the same as well.
Try coloring them differently:
cs1 = mesh(log(Kmatc0),log(Zmatc0),vc0_cp1,'EdgeColor',[1 0 0]) %red
hold on
cs2 = mesh(log(Kmatc0),log(Zmatc0),vc0_cp0,'EdgeColor',[0 0 1]) %blue
Note: if you only see the latter mesh (blue) they are coincident
  댓글 수: 2
Luca Ferro
Luca Ferro 2023년 3월 3일
did this help you out?
stefano lazzeri
stefano lazzeri 2023년 3월 3일
Luca, thank you for your help! That is exactly what I needed, since both value functions were ver close but not equal.

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

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 2-D and 3-D Plots에 대해 자세히 알아보기

제품


릴리스

R2022a

Community Treasure Hunt

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

Start Hunting!

Translated by