Is that possible to draw a scale bar in figure?

57 views (last 30 days)
I am using quiver function with scale factor 1. But for understand the differences between the points or precisely show the distances I need a scale bar which shows the scaling amount. how can I draw it in figure? By the way I am using coordinates with meter unit. And displacements are in cm level.
I tried these commands but it doesnt have a solution for me, any other ideas?
import data
h=quiver(x1, y1, v, u, 1,'ShowArrowHead','off');
text(max(x1)-20,min(y1)+20,'Scale= 4 cm','Color','r','FontWeight','bold');

Accepted Answer

Image Analyst
Image Analyst on 24 Nov 2013
Image Analyst
Image Analyst on 25 Nov 2013
I have not downloaded but it loook like you can jsut do
SCALEBAR(haxesPlot, 'ScaleLength', 1, 'Northeast');
like it directs in the comments. Did you try that?

Sign in to comment.

More Answers (2)

Sean de Wolski
Sean de Wolski on 3 Apr 2013

abuzer on 24 Nov 2013
I think this function needs grid references, but I need simple one, I've just reference coordinates and their displacements. how to figure out the results with scaled? thanks for answer


Find more on Vector Fields in Help Center and File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by