Clear Filters
Clear Filters

Where can I find data providing state and province boundaries for Mexico and Canada respectively for use with the Mapping Toolbox?

14 views (last 30 days)
I have an application that requires me to depict data all over the United States. I was able to obtain state boundaries for United States using the USALO and USAHI functions and the MAT-Files of the same name. Sometimes, my data extends beyond the United States and crosses into Mexico and Canada. I would like to obtain data providing the state/province boundaries for Mexico and Canada respectively in order to map such data.

Accepted Answer

MathWorks Support Team
MathWorks Support Team on 18 Jan 2024
Edited: MathWorks Support Team on 29 Feb 2024
This change has been incorporated into the documentation in Release 14 Service Pack 3 (R14SP3). For previous releases, read below for any additional information:
The following website provides information relelvant to your application:
From here, you can download "province.zip", which contains a shapefile consisting of the province boundary data for Canada. The SHAPEREAD command can be used to import this file into MATLAB. The file "mx_state.zip" in the same directory contains a shapefile MX_STATE.SHP which provides state boundaries for Mexico.
The coordinates of this data are latitude-longitude, so the following syntax of SHAPEREAD can be used to read in the data correctly:
s = shaperead('MX_STATE.SHP','UseGeoCoords',true);
Please note that as of Mapping 2.1 (R14SP2), the USAHI and USALO functions and associated MAT-files are no longer shipped. However, the data from those MAT-files does still ship with the Mapping Toolbox in shapefile format. See solution 1-12MDM2 for details.
See the Tech Note for more information on accessing geospatial data, including many publicly available Internet resources.
Accessing Geospatial Data on the Internet for the Mapping Toolbox.
Please run the below command in the MATLAB R2018b command window to get documentation:
web(fullfile(docroot, 'map/find-geospatial-data-online.html'))
Please follow the below link to search for the required information regarding the current release:

More Answers (0)

Products

Community Treasure Hunt

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

Start Hunting!