How to do a Quiver plot between two data sets?

조회 수: 1 (최근 30일)
Rafael Freire
Rafael Freire 2012년 11월 1일
How i make a quiver plot between each dot in the same line dot P1(1,:) with P2(1,:); P1(2,:) with P2(2,:) and on....
P1=[121.578100000000 6.97130000000000
115.047800000000 6.22980000000000
144.975100000000 7.44900000000000
116.170800000000 6.75630000000000
115.146500000000 6.68150000000000]
P2=[121.567800000000 6.98020000000000
115.059500000000 6.23620000000000
144.959200000000 7.44990000000000
116.141900000000 6.74180000000000
115.056800000000 6.67760000000000]
Best Regards

채택된 답변

Rafael Freire
Rafael Freire 2012년 11월 1일
편집: Rafael Freire 2012년 11월 1일
D=P2-P1
figure
for k=1:length(P1);
hold on;
quiver(P1(k,2), P1(k,1), D(k,2),D(k,1),0);
end
plot(P1(:,2), P1(:,1), '.b', 'markersize', 15)
plot(P2(:,2), P2(:,1), '.g', 'markersize', 20)

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Vector Fields에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by