主要内容

本页采用了机器翻译。点击此处可查看英文原文。

removeCustomBasemap

删除自定义底图

说明

removeCustomBasemap(basemapName) 将由 basemapName 指定的自定义底图从可用底图列表中移除。

如果之前尚未使用 addCustomBasemap 函数添加了由 basemapName 指定的自定义底图,则 removeCustomBasemap 函数会报错。

示例

示例

全部折叠

添加自定义底图,以便在 OpenStreetMap® 底图上查看位置。

name = "openstreetmap";
url = "a.tile.openstreetmap.org/${z}/${x}/${y}.png";
copyright = char(uint8(169));
attribution = copyright + "OpenStreetMap contributors";
addCustomBasemap(name,url,"Attribution",attribution)

在地理气泡图中使用自定义底图。

lat = [42.3501 42.3515 42.3598 42.3584 42.3529];
lon = [-71.0870 -71.0926 -71.0662 -71.0598 -71.0662];
gb = geobubble(lat,lon,"Basemap","openstreetmap", ...
    "BubbleWidthRange",25,"MapLayout","maximized", ...
    "ZoomLevel",14);

Figure contains an object of type geobubble.

删除自定义底图。

removeCustomBasemap(name)

输入参数

全部折叠

要删除的自定义底图的名称,指定为字符串标量或字符向量。在使用 addCustomBasemap 函数添加底图时,您需要定义底图的名称。

数据类型: string | char

版本历史记录

在 R2018b 中推出

另请参阅