How can I customly fix the Data cursor location in the Matlab plot?
29 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
Jaikrishnan Mahalekshmi Sahasranamam
el 17 de Jul. de 2019
Comentada: Jaikrishnan Mahalekshmi Sahasranamam
el 5 de Ag. de 2019
I have a plot (attached). In this plot I need to add two data cursors. In one of the data cursor, I need to fix the X value to be 0 and in the other i need to fix the y value to 0. How can I adjust the data cursor points to do so? currently in the first data tip, the Y value is -49.51 and in the other data tip the x value is 0.485. I need to make it in such a way as to keep Y value 0 in first and X value 0 in second. By doing this I will get the corresponding X value from 1st and corresponding Y value from 2nd
2 comentarios
Respuesta aceptada
Dinesh Yadav
el 2 de Ag. de 2019
I am assuming you have the equation used for plotting. You can feed the value “x=0” in the function to get the value of “y” and vice versa and store these values in variable “pos1” and “pos2”. Without having the values for both “x” and “y” you cannot obtain the DataCursor on the plot.
I am attaching a slightly modified code for your given code with which you can obtain DataCursor at any point of your choice. I have commented few lines that are not needed and changed few lines of code for updating DataCursors.
Más respuestas (0)
Ver también
Categorías
Más información sobre Title en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!