Using key presses w/ Radio Buttons in GUIDE figures
조회 수: 5 (최근 30일)
이전 댓글 표시
Hello, I have never used the GUIDE before and have been tasked with making a GUI for data parsing. Basically, I need to use figure toolbar/datacursor to progressively move through a large vector of data and put cursors at several (200+) points of interest. I also need to classify these points as signifying one of 4 different things. My idea is to control what each point I drop is classified as by toggling a different radio button on key press with q, w, e, and r. This way, someone using the GUI can use alt, qwer, and mouse clicks to quickly move through and parse the data.
Is this even possible? I've seen information on WindowKeyPressFcn, but have yet to figure out how to incorporate it into my GUI to toggle different radio buttons. Also, would clicking on my axes (object for graph within UI) to set datacursors cause a focus issue with the radio buttons?
Any advice you can offer would be greatly appreciated. In the mean time, I'm still struggling through the basics of the GUIDE...
댓글 수: 0
채택된 답변
Joe Yeh
2016년 10월 5일
Yes, you can certainly achieve this.
You can use 'q' 'w' 'e' 'r' keys to move a cursor ( a display object, for example, a scatter plot object ) across the display area. In the callback function for these key press actions, you would save the position of the scatter plot object to the handles structure and update its position. Then in another callback function for a radio button, you can save the position the display object is currently at to another field of the handles structure when the button is pressed.
댓글 수: 0
추가 답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Migrate GUIDE Apps에 대해 자세히 알아보기
제품
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!