plotting using data from a cell array
1 次查看(过去 30 天)
显示 更早的评论
Dear Friends,
i want to automatically draw a graph of marks of students vs their names. students names are in a cell array where as marks are in a vector array. is it possible to draw a graph straight away. Thanks in advance.
0 个评论
回答(1 个)
Yona
2014-9-22
figure
name = {'m1';'m2';'m3';'m4';'m5'};
y = [90,85,88,100,40];
bar(y)
set(gca,'xlabel',name)
2 个评论
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Line Plots 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!