adding two ticks to form a horizontal line
古いコメントを表示
How do I add two ticks in the plot editor so that it gives me a perfect horizontal straight line?
回答 (2 件)
Jonas
2021 年 6 月 30 日
if you want to add a horizontal line to you plot you can use yline. if you want a ytick at that specific value you can write
yline(3.3614);
yticks(unique([yticks() 3.3614]));
4 件のコメント
shahriar sowad
2021 年 6 月 30 日
編集済み: shahriar sowad
2021 年 6 月 30 日
shahriar sowad
2021 年 6 月 30 日
Jonas
2021 年 6 月 30 日
yes, add the two lines at the end of your code.
note that you just need one 'hold on' command, this will have the effect that all later plots are added to the current figure
shahriar sowad
2021 年 6 月 30 日
カテゴリ
ヘルプ センター および File Exchange で Grid Lines, Tick Values, and Labels についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!