필터 지우기
필터 지우기

How to Plot on x-y axis?

조회 수: 1 (최근 30일)
Islam
Islam 2013년 12월 26일
댓글: Matt J 2013년 12월 26일
The j, k and i positions are generated randomly and uniformly over [10,200] Here is the positions of i and j on the x-y axis
GJ = [48 179 197 134 92 26 85 135 119 132];
GI = [153 180 83 94 152];
GK = [121 81 169 200 48 67 179 106 93 94 17 31 101 192 167];
where 116 for instance represent the Euclidean distance between j=2 and i =2
first Question, Is there a Matlab line that can plot the i, j, k on an x-y coordinates in which J is symbolized with X's and k's are plotted as Y's and I are plotted as Z's

답변 (1개)

Matt J
Matt J 2013년 12월 26일
scatter3(GJ(:),GK(:),GI(:))
  댓글 수: 2
Islam
Islam 2013년 12월 26일
it tells me they should be of the same length ..
Matt J
Matt J 2013년 12월 26일
Whoops. Sorry,
[X,Y,Z]=ndgrid(GJ,GK,GI);
scatter3(X(:),Y(:),Z(:));

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

카테고리

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

태그

Community Treasure Hunt

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

Start Hunting!

Translated by