Problems using hold on when plot figure
2 ビュー (過去 30 日間)
古いコメントを表示
Tam Ho
2018 年 3 月 12 日
回答済み: Santosh Prasad Choudhury
2018 年 3 月 12 日
My code
colors = repmat('krgbmc',1,300) ;
Rtot =20;
L = 0:0.01:200 ;
KDs = 10:20:90 ;
figure
hold on
for i=1:length(KDs)
KD = KDs(i) ;
LR = Rtot*L./(L + KD) ;
LR_all(i,:) = LR ;
figure
hold on
plot(L,LR,colors(i)) ;
figurelegend(i) = ['K_D = ', int2str(KD),'uM'];
end
xlabel('[Ligand] (uM)')
ylabel('[Ligand-Receptor] (uM)')
legend(figurelegend,'Location','SouthEast')
1 件のコメント
Walter Roberson
2018 年 3 月 12 日
What difficulty do you observe?
You are asking to create a new figure for each plot. Is that your intent?
採用された回答
Santosh Prasad Choudhury
2018 年 3 月 12 日
Please replace your code by figurelegend{i} = ['K_D = ', int2str(KD),'uM']; and you are creating somany figures? Please let me know your intention.
その他の回答 (1 件)
Santosh Prasad Choudhury
2018 年 3 月 12 日
colors = repmat('krgbmc',1,300) ; Rtot =20; L = 0:0.01:200 ; KDs = 10:20:90 ; figure hold on for i=1:length(KDs) KD = KDs(i) ; LR = Rtot*L./(L + KD) ; LR_all(i,:) = LR ; plot(L,LR,colors(i)) ; figurelegend{i} = ['K_D = ', int2str(KD),'uM']; end xlabel('[Ligand] (uM)') ylabel('[Ligand-Receptor] (uM)') legend(figurelegend,'Location','SouthEast')
Please use above code and you will get your answer.
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で Annotations についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!