How to plot vector from data
3 visualizzazioni (ultimi 30 giorni)
Mostra commenti meno recenti
Hi,
I want to display 3D vectors. I got every channel in a different vector. Also Vec_X contains about 100 values and X is the axis. Vec_X(0) is the value that corresponds to X(0) Vec_X(n) to X(n).
And of course I also have Vec_Y and Y Vec_Z and Z.
What I want to do is display this as vectors. Plane XY, XZ, YZ and a 3D view of it. I started working with the matlab function quiver ( and quiver3 ). quiver(x,y,Vec_X,Vec_Y) but this doesn't work the way I want it to : It draws the vectors corresponding to the points (0,0) (1,1) (2,2) etc.. but (0,1) (0,2) etc are all missing.
Do you have an idea of what I could use ? The final objective is to find the point ( if it exists ) all these vectors are pointing at. So the graphic has to be readable.
Thanks for your help. If you have any question or if you don't understand what my objective is, I could paste some code lines :)
0 Commenti
Risposte (3)
Sean de Wolski
il 21 Mag 2012
Do you have a data point and corresponding vectors components for each of those (0,1), (0,2) etc.?
If you don't have points defined at these lcoations they won't be drawn and to get them you would have to interpolate.
More per comment/answers
doc meshgrid
use meshgrid to generate index matrices.
0 Commenti
Julien RUNTZ
il 21 Mag 2012
3 Commenti
Walter Roberson
il 21 Mag 2012
Or to make your life even easier on yourself, ndgrid() instead of meshgrid()
Vedere anche
Categorie
Scopri di più su Vector Fields in Help Center e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!