How to plot 3 different data in contour or pcolor ?
조회 수: 4 (최근 30일)
이전 댓글 표시
I have three different data
- Time steps = 1X108 (should be in X-axis)
- Data1 = 36X108 (should be in Y-axis(left))
- Data2 = 36X108 (should be display in colour/countour/pcolor)
Now I want to plot temporal plot (colour plot ) like the image I attached
댓글 수: 6
Ameer Hamza
2020년 5월 26일
something like this?
p = pcolor(dt, nw_bin, sizdist)
shading interp
xlabel('x');
ylabel('y');
colorbar
채택된 답변
Ameer Hamza
2020년 6월 2일
p = pcolor(dt, nw_bin, sizdist)
shading interp
xlabel('x');
ylabel('y');
colorbar
댓글 수: 2
Ameer Hamza
2020년 6월 2일
Try this code
Dt = repmat(dt, 36, 1);
[dt_grid, nw_bin_grid] = meshgrid(dt, mean(nw_bin, 2));
sizdist_grid = griddata(Dt(:), nw_bin(:), sizdist(:), dt_grid, nw_bin_grid);
contourf(dt_grid, nw_bin_grid, sizdist_grid)
shading interp
xlabel('x');
ylabel('y');
colorbar
추가 답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Contour Plots에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!