How do i select a point on matlab UIaxes and then get data for it?
Al momento, stai seguendo questa domanda
- Vedrai gli aggiornamenti nel tuofeed del contenuto seguito.
- Potresti ricevere delle e-mail a seconda delle tuepreferenze per le comunicazioni.
Si è verificato un errore
Impossibile completare l'azione a causa delle modifiche apportate alla pagina. Ricarica la pagina per vedere lo stato aggiornato.
0 voti
Condividi un link a questa domanda
Risposta accettata
2 voti
Condividi un link a questa risposta

22 Commenti
Condividi un link a questo commento
Condividi un link a questo commento
Condividi un link a questo commento
Condividi un link a questo commento
Condividi un link a questo commento
Condividi un link a questo commento
Condividi un link a questo commento
- Make sure the panning tool is not selected (see image below)
- Turn off panning from within the callback function using the line below.

Condividi un link a questo commento
Condividi un link a questo commento
- If you're using my function, just before drawrectangle() is called, the title should turn red which indicates that you can draw the rectangle without the axis limits moving around. If you click-and-drag before or after this window of time, the axis limits will be affected.
- Try disabling and enabling all interactivity prior to / after calling drawrectangle() (see below
Condividi un link a questo commento
Condividi un link a questo commento
Condividi un link a questo commento
- Removes any pre-existing datatips in the UIAxes
- waits for a datatip to appear after the user hovers over a data point
- displays the coordinates of the datatip
- If you want to get data from >1 datatip at a time, you could alter the while-loop to either count the number of expected datatips or add a stop-button that triggers the end of the while-loop.
- Depending on how dense your data are, you may want to remove the datatip after it's coordinates are stored so you don't end up with a bunch of datatips cluttering the axes.
- you'll probably want to store the coordinates rather than display them.
Condividi un link a questo commento
Condividi un link a questo commento
Condividi un link a questo commento
Condividi un link a questo commento
Condividi un link a questo commento
Più risposte (1)
0 voti
Condividi un link a questa risposta
2 Commenti
Condividi un link a questo commento
Condividi un link a questo commento
Categorie
Scopri di più su Interactive Control and Callbacks in Centro assistenza e File Exchange
Vedere anche
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!Seleziona un sito web
Seleziona un sito web per visualizzare contenuto tradotto dove disponibile e vedere eventi e offerte locali. In base alla tua area geografica, ti consigliamo di selezionare: .
Puoi anche selezionare un sito web dal seguente elenco:
Come ottenere le migliori prestazioni del sito
Per ottenere le migliori prestazioni del sito, seleziona il sito cinese (in cinese o in inglese). I siti MathWorks per gli altri paesi non sono ottimizzati per essere visitati dalla tua area geografica.
Americhe
- América Latina (Español)
- Canada (English)
- United States (English)
Europa
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)
