On 1/29/2013 3:17 PM, Chris wrote: > If I have a vector A and matrix B and make a bar plot, how do I list the > corresponding y values at the top of each bar? (I understand that you > use the text() function but I cannot get it to work). An example of what > I want to accomplish: > > A = [1 2 3 4 5]; > B = [4 7; 2 9; 3 7; 4 8; 1 3]; > bar(A,B); > > % how do I properly use text() or something else to insert the data > values located in B??
at the command line for example. You can then clearly use a loop or even vectorize the idea for the general case.