How to display values on the Sobol index plot automatically on top of the bars without using annotate or text function? I need to display the plot like the one attached here

1 次查看(过去 30 天)
I have obtained the plot for Sobol index using Global sensitivity analysis tool in matlab. Now in order to get the value of Sobol index clearly, i want the index value to be displayed on the top of the bar 1 and bar 2 as shown in the attached file for example. Is there any automatic way to do the same? I have gone through multiple documents, but everywhere the use of 'text' or 'annotate' is suggested, which is not my requirement. Any help is highly appreciable.

回答(1 个)

Shivam
Shivam 2023-10-13
Hi Darshna,
I understand that you want to label the bars of the plot without using the 'text' and 'annotate' functions.
You can use the 'barlabel' function to label the bars. You can download the 'barlabel.m' file through the following file-exchange link and keep it in the working directory. This resource should provide valuable insights on how to proceed with it.
I hope it helps to resolve your query.

类别

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

Community Treasure Hunt

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

Start Hunting!

Translated by