How to insert values on top of Each bar in Matlab also with names on x-axis.

1 次查看(过去 30 天)
*
with this code I am getting grouped bars with names on x-axis. now I would like to show the values of each bar on top of it, same like Excel*

回答(1 个)

Thorsten
Thorsten 2016-7-5
编辑:Thorsten 2016-7-5
Use
text(x, value, num2str(value))
and find out the appropriate values for x, and use 'VerticalAlignment', 'top' for negative values.

类别

Help CenterFile Exchange 中查找有关 Environment and Settings 的更多信息

标签

Community Treasure Hunt

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

Start Hunting!

Translated by