Info
이 질문은 마감되었습니다. 편집하거나 답변을 올리려면 질문을 다시 여십시오.
Making a contour plot with 1-D z values?
조회 수: 1 (최근 30일)
이전 댓글 표시
I have experiemntal splash data with X being the Weber number Y being the Reynolds number and Z being a number (1-5) depending on the splash pattern. I am trying to vissulize this data by using a contour plot but cannot figure out to format my code since my Z is not a matrix. I have attached my data and any help would be greatly appreciated. I have been able to create the contour plot attached but I need smooth lines and only integers in the legend. I would like my plot to look like similar to the screen shot uploaded.
답변 (1개)
darova
2019년 8월 22일
You dont so much points for meshgrid, just make FaceColor - interp
F = scatteredInterpolant(Re,We,PS);
PSg = F(Reg,Weg);
h = pcolor(Reg,Weg,PSg);
set(h,'FaceColor','interp')
set(h,'EdgeCOlor','none')
caxis([0 5])
hc = colorbar;
set(hc,'YTick',0:5)
set(hc,'YTickLabel',0:5)
xlim([0 6000])
ylim([0 2000])
댓글 수: 4
참고 항목
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!