set(gca,'Y​dir','reve​rse') not working in Quiver plots

I am using Matlab 2010. I have to reverse the Y axis and for simple plots set(gca,'Ydir','reverse') is working fine. But when i am using set(gca,'Ydir','reverse') for Quiver plots, its not working. Yes i can manually reverse the axis after the quiver plot is ready ie from property editor but i want to save the plot on the go using Print and want set(gca,'Ydir','reverse') to work properly.
Please help . Too much time had been wasted by me on this. Can not get it right
Thanks Bineet

1 commentaire

dpb
dpb le 3 Août 2016
Show sample that doesn't seem to work right (and the code that generated it...if it's an issue with quiver itself somehow the example data in the doc should be sufficient to reproduce the issue).
It seems to have no issues here w/ R2012b or R14; I don't have anything between but I think it must be something you're doing elsewhere in creating the plot that's causing the issue like there being a second axes or somesuch, not related to quiver; that you're using quiver is, I think a red herring like in the junior high pre-algebra word problems the extraneous information was thrown in to trip you up...

Connectez-vous pour commenter.

Réponses (1)

Vishwarath Taduru
Vishwarath Taduru le 23 Nov 2016

0 votes

i am finding the same issue. Did anyone come up with a solution?

4 commentaires

Works for me in R2016b. Which MATLAB release are you using?
dpb
dpb le 23 Nov 2016
See earlier comment; besides late releases, I showed it works as early as R14 and in R2012b; just tested it also is ok back to R11.
As noted there, whatever it is you're seeing, I don't think it has anything to do with quiver per se; but SHOW THE ACTUAL CODE and resulting symptom that creates the issue...if it were quiver which really has the issue (and it isn't; the axis direction is an axis property; the quiver plot is simply plotted into an axis) the example in the doc will suffice.
JG
JG le 14 Mai 2021
I have the same problem when using a sub plot. It is as if set(sub_plot_handle, 'YDir', 'reverse') is being ignored. Doesn't matter what direction I set. I'm running r2021a. If I use set not on a sub plot, it works.
dpb
dpb le 14 Mai 2021
Again, unless we have actual code the produces the symptom, we can't try to reproduce and can only report that things work as expected elsewhere (albeit I don't have R2021a, I'm on R2020b, but I'd guess if this were a generic issue it would have many more reports of the problem by now).

Connectez-vous pour commenter.

Catégories

En savoir plus sur Vector Fields dans Centre d'aide et File Exchange

Commenté :

dpb
le 14 Mai 2021

Community Treasure Hunt

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

Start Hunting!

Translated by