removeCustomBasemap
Remove custom basemap
Description
removeCustomBasemap(
removes the
custom basemap specified by basemapName
)basemapName
from the list of available
basemaps.
Examples
Add and Remove a Custom Basemap
Add a custom basemap to view locations on an OpenTopoMap® basemap, then remove the custom basemap.
Specify values for these arguments:
A name that identifies the custom basemap.
The URL of the map tiles. For load balancing, this provider has three servers that you can use (
a
,b
, orc
).An attribution that gives credit to the provider of the map tiles. When you plot data, this attribution appears at the bottom of the map. Map tile providers can define specific requirements for the attribution.
A display name for the custom basemap. This name appears in the Imagery tab of Site Viewer.
name = "opentopomap"; url = "a.tile.opentopomap.org/${z}/${x}/${y}.png"; copyright = char(uint8(169)); attribution = copyright + "OpenStreetMap contributors"; displayName = "Open Topo Map";
Use addCustomBasemap
to load the custom basemap, and then create a Site Viewer that uses the custom basemap.
addCustomBasemap(name,url,'Attribution',attribution','DisplayName',displayName) viewer = siteviewer('Basemap',name);
After you add a custom basemap, the custom map is available in new Site Viewer windows. Note the Open Topo Map basemap icon in the Imagery tab.
siteviewer;
Use removeCustomBasemap
to remove the custom basemap. Then, open a new Site Viewer. Note the Open Topo Map basemap option is no longer available in the Imagery tab.
removeCustomBasemap(name) siteviewer;
Input Arguments
basemapName
— Name of custom basemap
string scalar | character vector
Name of the custom basemap to remove, specified as a string scalar or character
vector. You define the basemap name when you add the basemap using the
addCustomBasemap
function.
Data Types: string
| char
See Also
geoaxes
| geobasemap
| geobubble
| geodensityplot
| geoplot
| geoscatter
| addCustomBasemap
Open Example
You have a modified version of this example. Do you want to open this example with your edits?
MATLAB Command
You clicked a link that corresponds to this MATLAB command:
Run the command by entering it in the MATLAB Command Window. Web browsers do not support MATLAB commands.
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list:
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
- América Latina (Español)
- Canada (English)
- United States (English)
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)