Change datatip label when using DefaultInteractivity on UIAxes in App Designer
8 visualizzazioni (ultimi 30 giorni)
Mostra commenti meno recenti
I have a 3D plot on an UIAxes in App Designer that is generating data points at specified x,y and z coordinates. Each of these points corresponds to a a physical location along a vehicle and I have the string descriptions of each stored in an array. I would like to display this description in place of or alongside the coordinates. Is this possible to do in Matlab ver. 2019b?
0 Commenti
Risposte (1)
Sameer
il 30 Mag 2025
Hi @Jimmy Smith
It is possible to display string descriptions alongside data points in a 3D plot on a "UIAxes" in App Designer. This can be done using the "text" function, which allows adding text labels at specified x, y, and z coordinates.
Assuming the coordinates are stored in vectors "x", "y", and "z", and the descriptions are in a string array "labels", the following can be used:
for i = 1:length(x)
text(app.UIAxes, x(i), y(i), z(i), labels(i));
end
This will place each label at the corresponding 3D point. The labels will appear next to or on top of each data point in the "UIAxes".
Hope this helps!
0 Commenti
Vedere anche
Categorie
Scopri di più su Develop Apps Using App Designer in Help Center e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!