How do I rotate the X and Y axes of my histogram in MATLAB (R2011b)?

49 次查看(过去 30 天)
I have a histogram for which I want to rotate the X and Y axes by 90 degrees. How can I achieve that?

采纳的回答

MathWorks Support Team
To rotate the axes, you would need to get their handle and modify the 'View' option. Here is an example to illustrate this:
>> N = 1000;
>> binCount = 100;
>> figure
>> hist(gca,rand(N,1),binCount);
>> set(gca,'view',[90 -90]

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Annotations 的更多信息

产品


版本

R2011b

Community Treasure Hunt

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

Start Hunting!

Translated by