MATLAB 帮助中心
Create copy of binary occupancy map
copyMap = copy(map)
copyMap = copy(map) creates a deep copy of the binaryOccupancyMap object with the same properties.
copyMap
map
binaryOccupancyMap
example
collapse all
This example uses:
Copy a binaryOccupancyMap object. Once copied, the original object can be modified without affecting the copied map.
Create an occupancy map with zeros for an empty map.
p = zeros(10); map = binaryOccupancyMap(p);
Copy the occupancy map. Modify the original map. The copied map is not modified. Plot the two maps side by side.
mapCopy = copy(map); setOccupancy(map,[1:3;1:3]',ones(3,1)); subplot(1,2,1) show(map) title('Original map') subplot(1,2,2) show(mapCopy) title('Copied map')
Map representation, specified as a binaryOccupancyMap object. This object represents the environment of the vehicle.
Copied map representation, returned as a binaryOccupancyMap object. The properties are the same as the input object, map, but the copy has a different object handle.
Introduced in R2015a
binaryOccupancyMap | occupancyMap
occupancyMap
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.
选择网站
选择网站以获取翻译的可用内容,以及查看当地活动和优惠。根据您的位置,我们建议您选择:。
您也可以从以下列表中选择网站:
如何获得最佳网站性能
选择中国网站(中文或英文)以获得最佳网站性能。其他 MathWorks 国家/地区网站并未针对您所在位置的访问进行优化。
美洲
欧洲
亚太
联系您当地的办事处