plot using with characters which are cell and numeric data.
54 ビュー (過去 30 日間)
表示 古いコメント
data=[1;2;3;4;5;6];
ids={'12.1a';'1.2b';'1.3c';'1.4d';'1.7e';'1.8f'}
%I wanna plot the data and ids like, plot(ids,data,'b') but Conversion to double from cell is not possible error occurs.
%How I can handle this cellarray for plot?
0 件のコメント
採用された回答
Azzi Abdelmalek
2014 年 12 月 25 日
編集済み: Azzi Abdelmalek
2014 年 12 月 25 日
data=[1;2;3;4;5;6]
ids={'12.1a';'1.2b';'1.3c';'1.4d';'1.7e';'1.8f'}
plot(data,'b')
set(gca,'XTick',1:numel(ids))
set(gca,'XTickLabel',ids)
その他の回答 (0 件)
参考
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!