Colour plot using single x, y and multiple z values

조회 수: 2 (최근 30일)
aa
aa 2020년 8월 20일
편집: KSSV 2020년 8월 22일
Hi everyone,
I have data with single x-axis, singel y-axis and multiple z-axis. I want to plot the values of z againts x-y in colour map.
my simple data set is attached (first coloumn is x-axis, 2nd column is y-axis and rest of the colymns are z-axis) here along with the required output plot.

답변 (1개)

KSSV
KSSV 2020년 8월 20일
num = xlsread("data.xlsx") ;
x = num(:,1) ;
y = num(:,2) ;
Z = num(:,3:end) ;
pcolor(x,y,Z) ;
shading interp ;
colorbar
  댓글 수: 2
aa
aa 2020년 8월 22일
Thank you. This works very work and serve the purpose.
KSSV
KSSV 2020년 8월 22일
편집: KSSV 2020년 8월 22일
Thank you is accepting the answer..

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

카테고리

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