how to assign names to each bar of a bar chart (2025)

Hello, Suppose i have some data that i want to plot in a bar chart. How do i assign labels to each of the bars. e.g.

somedata=randn(1,3)

somenames={'mike'; 'steve'; 'alex' }

barh(somedata)

My question is, how do i label each of the bars to the extreme left with the names.

Thank you for your help.

0 Comments

Show -2 older commentsHide -2 older comments

Sign in to comment.

how to assign names to each bar of a bar chart (2025)
Top Articles
Latest Posts
Recommended Articles
Article information

Author: Laurine Ryan

Last Updated:

Views: 6670

Rating: 4.7 / 5 (57 voted)

Reviews: 88% of readers found this page helpful

Author information

Name: Laurine Ryan

Birthday: 1994-12-23

Address: Suite 751 871 Lissette Throughway, West Kittie, NH 41603

Phone: +2366831109631

Job: Sales Producer

Hobby: Creative writing, Motor sports, Do it yourself, Skateboarding, Coffee roasting, Calligraphy, Stand-up comedy

Introduction: My name is Laurine Ryan, I am a adorable, fair, graceful, spotless, gorgeous, homely, cooperative person who loves writing and wants to share my knowledge and understanding with you.