all values ​​on the surf chart

1.pngI create a graph of surf (X, Y, Z, C), when I click on the graph, I will get X, Y, Z. Is there any way to get C to display ?

1 comentario

Adam Danz
Adam Danz el 24 de Nov. de 2019
Editada: Adam Danz el 21 de En. de 2020
@ Lev Mihailov, if answers to your questions are helpful, accept the answer so others know it worked for you. Volunteers appreciate that feedback.

Iniciar sesión para comentar.

Respuestas (1)

Adam Danz
Adam Danz el 22 de Nov. de 2019
Editada: Adam Danz el 22 de Nov. de 2019

0 votos

Here's a demo
[X,Y] = meshgrid(1:0.5:10,1:20);
Z = sin(X) + cos(Y);
s = surf(X,Y,Z);
row = dataTipTextRow('C',s.CData); % define new row to datatip
s.DataTipTemplate.DataTipRows(end+1) = row; % add new row to datatip
For more info:

Categorías

Más información sobre 2-D and 3-D Plots en Centro de ayuda y File Exchange.

Productos

Preguntada:

el 22 de Nov. de 2019

Editada:

el 21 de En. de 2020

Community Treasure Hunt

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

Start Hunting!

Translated by