Plotting certain values of a matrix
2 ビュー (過去 30 日間)
古いコメントを表示
Hello I have a 100x1 matrix and would like to plot n=2 and n=100 values against x how would I go about doing this? Thanks for any help
0 件のコメント
採用された回答
madhan ravi
2019 年 3 月 17 日
plot(repmat(100,100,1),x)
% ^^^-—-—-n
hold on
plot(repmat(2,100,1),x)
9 件のコメント
madhan ravi
2019 年 3 月 17 日
編集済み: madhan ravi
2019 年 3 月 17 日
'y' represents color of the plot which is yellow.
See my original answer after using hold on plot another line to the same figure
doc hold
doc plot
I suggest you to do MATLAB onramp course which is free and takes few hours to complete by then you will get know the basics of MATLAB.
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Logical についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!