Hello everyone, sorry I'm asking what seems like a rudimentary question but I've probably spent the better half of an hour online trying to solve my problem and I have not gotten anything to work. I'm making a quiver plot with specific vectors at specific locations using the plot function:
quiver(x,y,u,v)
unfortunately, my plot is what is shown below...
Those are arrows believe it or not. I can't seem to find a simple solution to making the arrow heads not so wide! My data in the x direction only varies from .6 to .7 but the x axis has been severely widened due to these wide arrows. Thank you for any help!

댓글 수: 4

Walter Roberson
Walter Roberson 2017년 4월 24일
I have been fighting this as well, especially for quiver3. Not everything is affected, but I have not figured out when it happens.
crisdeodates
crisdeodates 2020년 2월 27일
Are there any leads on this issue? I used to get the arrows in Quiver3 correctly for a while, and alas!! all of a sudden one day, all the heads became so wide!! I still wonder what happened as I didnt change anything with the code. Might be an issue after MATLAB update? In anycase, waiting for a promising solution by the fellow community members....
I think it has something to do with the values in both axes. They need to be have similar values in order for the arrows to display properly.
Joaquin Guillamon
Joaquin Guillamon 2021년 8월 21일
Hi Pablo, I'm writing regading a similar issue with the width of the arrows in the quiver plot you've got some years ago. Could you realized what was the problem?? I've tried a lot of different things but cannot make it look nice those arrows... If you know how to solve it, I appreciate any suggestion or help you can give me! Thanks!

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

답변 (2개)

Andrew Newell
Andrew Newell 2017년 4월 23일

0 개 추천

Have you tried looking at the documentation for quiver? There is an option
quiver(...,scale)
In your example, you could try
scale=0.1;
quiver(x,y,u,v,scale)
and tweak scale to get what you want.

댓글 수: 4

Andrew Chen
Andrew Chen 2017년 4월 23일
Thanks for your response. I have tried this and unfortunately this does not decrease the width but only "squishes" the arrow head from tip to tail. The arrow remains just as wide.
Sorry! Try this:
h = quiver(x,y,u,v);
hs = get(h,'MaxHeadSize');
set(h,'MaxHeadSize',hs/10)
Andrew Chen
Andrew Chen 2017년 4월 24일
I've never come across this notation before. It doesn't seem to work. How would this code factor into actually plotting the quiver plot? I will do some searching to see if I can find an answer and will let you know if I find one if I do before you respond.
Andrew Newell
Andrew Newell 2017년 4월 24일
Working with Graphics Objects may help familiarize you with my use of h and the get/set interface. It certainly works in tests I have done.

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

Timothy Russell
Timothy Russell 2017년 5월 26일

0 개 추천

Another question I have about the quiver3 plot...I'm trying to graph a vector in 3D and want to save a picture of it at a certain angle but the arrow head doesn't show up well at that angle. Can I somehow rotate the vector so the arrowhead shows up? thanks, tim

댓글 수: 1

KAE
KAE 2020년 2월 11일
Make this a separate question and you are more likely to get an answer.

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

카테고리

도움말 센터File Exchange에서 Vector Fields에 대해 자세히 알아보기

질문:

2017년 4월 23일

댓글:

2021년 8월 21일

Community Treasure Hunt

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

Start Hunting!

Translated by