plotting a matrix in matlab
이전 댓글 표시
I have a 10 in 10 matrix. I want to plot the matrix in the way that each elements present the number. can you help me with that?
답변 (1개)
Star Strider
2020년 5월 2일
I have no idea what result you want.
Try these:
M = randi(99, 10); % Create Matrix
[X,Y] = ndgrid(1:10);
figure
stem3(X(:), Y(:), M(:), 'filled')
grid on
figure
bar3(M)
grid on
.
댓글 수: 2
talayeh tavangar
2020년 5월 2일
Star Strider
2020년 5월 2일
My pleasure!
Still guessing what you want.
Try this:
figure
imagesc(M)
and this:
figure
surf(M)
view(0, 90)
.
카테고리
도움말 센터 및 File Exchange에서 Graphics Object Properties에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!