displaying values

I have a sine wave,in which i have take positive curve(upper curve), now if i click anywhere in that graph i want to display values of x,y,using gui ,please help

 Respuesta aceptada

Oleg Komarov
Oleg Komarov el 24 de Feb. de 2012

0 votos

You can use datacursormode to display datatips.
Check the examples.
EDIT the simplest example
function myGUI
figure('menubar','none','name','myGUI','numbertitle','off','resize','off');
plot(1:10)
datacursormode
end

5 comentarios

FIR
FIR el 25 de Feb. de 2012
oleg can u explain it clearly plz,i did not understand
FIR
FIR el 25 de Feb. de 2012
If i click at some area i want to display x and y values,using gui,if possible can u send the codes
FIR
FIR el 27 de Feb. de 2012
Oler i am new to this gui,if i type these in command window i get error ,please help
FIR
FIR el 27 de Feb. de 2012
Oleg if i click on that grapg where ever on the line and near by the line the values of x and y must be displayed,in each x and y boxes
Oleg Komarov
Oleg Komarov el 27 de Feb. de 2012
You have to save it as a function and then call the function myGUI to see the effect.

Iniciar sesión para comentar.

Más respuestas (0)

Categorías

Más información sobre Model Predictive Control Toolbox en Centro de ayuda y File Exchange.

Preguntada:

FIR
el 24 de Feb. de 2012

Community Treasure Hunt

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

Start Hunting!

Translated by