GUI graph with strings as axis
5 ビュー (過去 30 日間)
古いコメントを表示
how can I make several strings the x-axis for a graph in a GUI
2 件のコメント
採用された回答
Adam Danz
2019 年 5 月 10 日
編集済み: Adam Danz
2019 年 5 月 10 日
Here's a demo
ax = axes(); %Instead of this line, use the axis handle from your GUI handles
xTickVals = [2,4,6]; %<-- where you want the ticks
xlim([1,7]) %<-- make sure the ticks are within range
xTickLables = {'RO', 'BG', 'TR'}; %<-- your tick labels
set(ax, 'XTick', xTickVals, 'XTickLabels', xTickLables) % <-- set the ticks & labels
0 件のコメント
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Axis Labels についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!