Hi,
I want to give names to some graphs in a plot, and add a legend for them in app designer, but app designer doesn't recognize the common functions for them. Also I want to change the plot's name with each callback, is this possible?
I write this code in each callback:
plot(app.Plot, XYReferenceINT(:,1), 0*XYMeasureoffset(:,2),'-b','DisplayName','Measure')
title('Measure')
legend(h,'Location','NorthEastOutside')
Thanks for your help!

 채택된 답변

Cris LaPierre
Cris LaPierre 2018년 11월 16일

0 개 추천

You likely need to tell it which axes to add the title and legend to. Try
title(app.Plot,'Measure')
legend(app.Plot,h,'Location','NorthEastOutside')

추가 답변 (0개)

카테고리

도움말 센터File Exchange에서 Creating, Deleting, and Querying Graphics Objects에 대해 자세히 알아보기

질문:

2018년 11월 16일

답변:

2018년 11월 16일

Community Treasure Hunt

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

Start Hunting!

Translated by