How can I use plotm from the mapping toolbox in AppDesigner

5 Ansichten (letzte 30 Tage)
Scott
Scott am 24 Okt. 2017
Kommentiert: Adam Danz am 9 Aug. 2019
Looking to include Map data how can I include a plotm in a AppDesigner app?

Antworten (1)

Cam Salzberger
Cam Salzberger am 24 Okt. 2017
Hello Scott,
I do not believe that map axes can be used with uifigures (which is the type of figure used in App Designer). A map axes is simply a regular axes with extra metadata, and only uiaxes are usable with uifigures. As a result of this, plotm cannot be used, since it requires a map axes to function.
You won't have the same projection options, but you can simply plot latitude and longitude as y and x values on a uiaxes. Alternatively, you can open up a separate figure from within your app to display the map information.
-Cam
  2 Kommentare
babak ashory
babak ashory am 15 Dez. 2018
Bearbeitet: babak ashory am 15 Dez. 2018
How can I plot latitude and longitude values ​​as y and x in Uiaxes?
Adam Danz
Adam Danz am 9 Aug. 2019
You can try creating the map figure and then copying it to your GUI axes. Here's a working demo (r2019a)
h = worldmap('World'); % Store the output handle
hCopy = copyobj(h.Children, app.UIAxes); % Copy all of the axis' children to your app axis
delete(h.Parent) % get rid of the figure created by worldmap()

Melden Sie sich an, um zu kommentieren.

Kategorien

Mehr zu Develop uifigure-Based Apps finden Sie in Help Center und File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by