How do i create checkboxes near each plots in a subplot window ?

I have two graphs plotted in a subplot.Now ,near each plot i want a checkbox to be shown .
This will help the user know which plot he has selected .How do i do this ?
Any help will be appreciated.
Thank you

 採用された回答

Rik
Rik 2019 年 4 月 8 日

0 投票

6 件のコメント

Sachin NARAIN
Sachin NARAIN 2019 年 4 月 8 日
編集済み: Sachin NARAIN 2019 年 4 月 8 日
Yeah .The boxes shoud be positioned just near to the plot and it should return the value of the graph .Can you give me an example of this so that when the user selects the checkbox, the value it returns ,is the value of the graph selected?
Rik
Rik 2019 年 4 月 8 日
Can you give an example graph to work with, and can you describe what the desired outcome should be? 'the value of the graph' is very vague, and it is also unclear what you mean by returning a value in this context.
Sachin NARAIN
Sachin NARAIN 2019 年 4 月 8 日
there is a vriable val which has coordinates of a two signals .I have attached the screenshot of how i want the graphs and the checkboxes to be .
By value i mean , mmay be a function call which tells me wther the 1st plot was chosen or 2nd one .Capture.PNG
Rik
Rik 2019 年 4 月 8 日
if you store the handle to the checkbox, you can use val=get(h_checkbox,'Value') to load the state of the checkbox.
Rik
Rik 2019 年 4 月 10 日
Did this suggestion solve your problem? If so, please consider marking it as accepted answer. It will make it easier for other people with the same question to find an answer. If this didn't solve your question, please comment with what problems you are still having.
Sachin NARAIN
Sachin NARAIN 2019 年 4 月 11 日
Yes , it solved a part of the problem .I am going to post another question on the same logic putting up my code

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

その他の回答 (0 件)

カテゴリ

ヘルプ センター および File Exchange2-D and 3-D Plots についてさらに検索

タグ

タグが未入力です。

質問済み:

2019 年 4 月 8 日

コメント済み:

2019 年 4 月 11 日

Community Treasure Hunt

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

Start Hunting!

Translated by