how do i set the positions of checkbox near each plot in my Figure ?

2 ビュー (過去 30 日間)
Sachin NARAIN 2019 年 4 月 24 日
I have a subplot of two figures and i want to put two checkboxes near to each figure and a push button in the middle of the two plots .Currently i have the checkboxes and the push button but i am not able to position this near the plots .
I have formed the code and can you please tell me what exactly to add so that i can get the required result .
Thank you
I am attaching a part of my code to this question and also the plot .
I have got the position of the two plots but not getting the result.
function [M] = checkbox_Plot(Annot,value,idx_1,no_fig)
M = zeros(1,5);
%length_Annot = length(Annot);
for l = 1:length(idx_1)
%vec_ToPlot = value(l,:);
d = figure(no_fig);
sgtitle(Annot);
subplot(numel(idx_1),1,l);
%sgtitle(name);
ax(l) = gca;
pa = get(ax(l),'Position'); % position of subplot axes
plot(value(l,:));
set(ax(l),'XtickLabel',{},'YtickLabel',{},....
'Xtick',[],'Ytick',[],'TickLength',[0 0])
h(l) = uicontrol('Style','checkbox',....
'Position',[100 100 84 22],....
'String',['Press_' num2str(l)],....
'Callback' , @box_value);
end

サインインしてコメントする。

カテゴリ

Help Center および File Exchange2-D and 3-D Plots についてさらに検索

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by