Today we will be making maps that can be published on the internet (and actually publishing them)!
The process of publishing the map is actually quite straight forward, however, the cartographic principles we use do change somewhat. Up to this point, we have had a great deal of control over how our maps are viewed: we have been able to pick the paper size, we have been able to set the scale, and have been able to adjust the position of the elements carefully to avoid overlap. However, as we enter the world of web mapping we no longer get to know what screen size the user will have, the user gets to choose the zoom level, and position. It then becomes our job as cartographers to use the tools we have to make the display as robust as possible to clearly communicate with users regardless of how they view our web map.
For today’s lab, we will be recreating the NTS web map that we looked at all the way back in the second lab:
As well as looking at another approach to mapping the ICBC Crash data.
Our first web map
Start by creating a new project in ArcGIS Pro for your ‘NTS Map’ inside of your GEOG205 folder. The process for making a web map starts out exactly the same as a paper map. Where we will see differences is in the styling as we will not have exact control of what zoom or extent the end user will see; this will require making design choices that will be robust to different positions. This may mean making some compromises on the overall styling to ensure a consistent user experience.
Inside L:\GEOG205\lab07\nts_snrc you will find layers nts_snrc_50k, nts_snrc_250k, nts_snrc_1m, and prov_territo. Add all 4 layers to your map. You should have something as below:
Rearrange the layers as follows
Because this will be a web map, we want to change the projection to Web Mercator (EPSG 3857), this can be done by right-clicking on the ‘Map’ in the Drawing order, going into Properties, then Coordinate Systems and searching for ‘web’ or ‘3857’.
If you were publishing a 3D scene you would want unprojected data EPSG 4326.
Next, we will start working through this one layer at a time, turn off all layers except prov_territo. We will style this with the Unique Values symbology. Click ‘add all values’ in the Symbology pane if they don’t turn up in the list on their own.
When we start adding the map tile layers, we will style and add labels. This will start to look cluttered, but at this stage trust the process as we will be returning to change how the layers interact with each other after they are all added.
Add the 1:1 000 000 map grid (nts_snrc_1m).
- Make the styling a hollow outline, the colour can be whatever you wish
- Add labels using the ‘IDENTIF’ field
- Text should be 16pt with a halo
- Placement should be set to ‘Land Parcel’
At this stage you should have a functional index of the 1:1M map sheets.
Next, we will add the 250k layer; use a similar pattern for styling, this time using the NTS_SNRC field for label text.
You may wish to use a different colour for clarity; as well as making the lines thinner to denote that it is, in comparison, a minor division.
Scale and Web maps
Map scale works differently on the web. Generally speaking, we refer to zoom levels as opposed to scale when making web maps; in part, because we do not know how big the end-users screen will be compared to its resolution. Practically, this means that we will see some strange scales that are not round numbers. Fear not–this will not impact your grade, as it is merely the software going to its natural zoom levels.
You can see this when looking at a google maps URL such as https://firstname.lastname@example.org,-122.6068734,10.9z. The end of this URL has a z-value: this is the zoom. Historically, the z value was always a whole number between 1 (entire earth) to 20 (maximum zoom), however these days due to the variety of screen resolutions and a desire for intermediate zoom levels, the z is generally a decimal number.
Back to our ArcGIS projects, as the multiple scales are now cluttering the map, the next step will be to leverage scale-based visibility to turn the layers on and off.
The goal at this stage is that as the map is zoomed in, the line work for more coarse layers should remain, however the labels should be hidden when the next layer appears.
Start by zooming such that the labels for the 250k map sheets fill most of the tile, we want the labels to be clearly visible, but still contained within their boundaries.
We will now set the Label In Beyond (Minimum Scale) property of the 1:1M layer to <current>. What this means is the labels will be turned off if the scale is more coarse than the current view. Think of this setting as “The layer will be IN view only BEYOND (more coarse than) scale X.” Find a zoom level that seems logical, note that due to different screen resolutions, you may have a slightly different zoom level that ArcGIS Pro naturally goes to while zooming, this is OK. What will matter however is that you are using the same scales to turn off one layer, and turn another one on to avoid glitches where they are both present or both missing if this is not the desired effect.
Now, select nts_snrc_250k, go to the Feature Layer Tab, and set the Out Beyond here to the same value (You will see it in your history directly below <None>. This will cause the line-work to be turned off when we zoom out.
We will stop here and make sure that everyone is caught up to this point.
Finally, we will add the 50k tiles, in a similar style as before using a hollow symbol, and set the labels to the NTS_SNRC field, with 16pt font with a halo, finally set the and zoom to fit the labels fit comfortably inside.
Set the 50k layer for both appearance and label to Out Beyond this current Zoom. And the 250k labels to In Beyond the current Zoom
One more thing we can do to make the map more usable is to set the prov_territo layer to In Beyond the same scale we used to activate the 250k layer, this will allow us to see the map below the polygons.
Zoom in or out to the extent you would like to be the starting point of your web map.
Publishing our map
Publishing the map is very easy once the layers are set up with the correct styling. This is also a good time to rename your layers in drawing order before uploading; this will be easier to change now than after publishing.
Sign in to UNBC ArcGIS Portal if needed, then go to the Share tab, and press Web Map.
Before the map can be published, we need to specify a few details, including: the name of the map, a brief summary, and a comma separated list of tags (keywords we can use to find the map later.) And we want to set sharing to Everyone.
For Location / Portal folder you should see your folder available. Choose that folder.
Once you have these settings, press the analyze button.
You will likely see a couple of warnings here:
The first one saying that the Data Source is not registered, and will be copied to the server. And the second one saying the projection is different (all web maps will be Mercator, but the NTS shape files are Canada Albers) they will be re-projected on the server, but it will take some extra time to process).
If any errors are present (red X) they will need to be addressed before publishing. It is possible you will see Unique numeric IDs are not assigned. If so, double click on the message and it will open a window allowing you to enable the unique ID’s.
Finally Press Share
And wait, this is not a very fast process, as all of the layers need to be uploaded to the server and re-projected.
When it is finished you will get a success message, click on the Manage the Web Map button.
This will open a web page with information about your map. The URL in the web browser could be shared with others allowing them to view your map.
To see the map, press “Open in Map Viewer”
You have now published your first web map!
You will also notice that it loads faster than in ArcGIS Pro, this is largely due to the data being stored in an enterprise database as opposed to shapefiles.
You also have the option of publishing layers. This will make the layers available in the portal, to be used on a variety of maps. This has the advantage that if the layer is updated, all maps that rely on this will also be updated (when might this be a bad thing?).
By default, any layers you add from the portal are added to the map by ‘reference’: that is, the data will not be uploaded again when you share your map. Layers added from the filesystem will be uploaded with the map (it is possible to reference these later, however they will contain less metadata).
To do this, go back to ArcGIS Pro and right click on the layer you want to upload, choose sharing and Share As Web Layer.
*Note if you want to edit an existing web layer, you could open it, edit in ArcGIS Pro, and then Overwrite Web Layer if you have editing permission on the layer. But a word of caution, this will overwrite the original data and it would likely be wise to save a backup before overwriting.
Otherwise it is the same process of setting a Name, Summary, Tags, and Location (again your folder is fine).
Click Analyze to check for errors, if no errors are present press Publish.
In your web browser, visit this webpage https://arc.gis.unbc.ca/portal/home/index.html. This is the web interface to the portal we have been using throughout the semester. Your credentials are the same <username>@UNI. And you will find the Sign in button in the upper right corner of the map.
Once you are logged in you will be presented with the welcome page and a selection of icons across the top.
Home – This is the default page, there is little reason to be here.
Gallery – This is where you can view all the public data / maps from the UNBC GIS Lab in the portal: a good place to go exploring.
Map – This is where we will be working today to build our second web map.
Scene – Just as Scene represented 3D in ArcGIS Pro so it does here as well, you can play around with this if you wish, but it does have known issues crashing some web browsers.
Content – This is where you can find and manage all the content that you have published (Your map from part 1 will be in here).
Organization – This is for website administration, and there will not be anything you can edit here.
Let’s go into the map tab and start exploring
In general you will find this to be a simplified version of ArcGIS Pro. We will be creating a map similar to the heat map of ICBC claims in lab 5 but using a different technique for symbolization known as clustering.
Start by naming your map using the Save command near center in the menu bar on the left side of the page.
You will find that saving a map on the web asks for more information than in ArcGIS Pro.
To save your map please set the category to GEOG205, and add Tags for ICBC, WebMap and Homework. The save in folder will default to your username, as you have not yet created any subfolders, and this default location is perfectly ok for our purposes today.
Click Save map.
Now add the ICBC Claim layer
You will need to change the drop down from My Content to My Organization. You can search for “lower” and you will be able to find a layer called LowerMainlandCrash, there is a + in a circle at the bottom of this card, press it to add this dataset to your map.
Now we will apply a technique for simplifying the map called clustering, looking along the right hand side of the interface there are various controls for working with layers, find the clustering button and enable it for this layer.
You also have the option of changing the symbol attributes by using the Styles Menu
Many of the tools in ArcGIS Pro are available to you here, once you have a map you like you can enable Sharing along the Left Hand side
When you share the URL to the map, the Guest users will be presented with the extent you had when you last clicked save. A very helpful feature for this is that when layers are added to a web map, if that layer is updated inside of ArcGIS Enterprise, the map you created will be updated to reflect this. However this also comes with a note of caution that the map you created may not continue to work if dependent layers are removed.
For this week, please make sure to read the entire assignment before beginning. Pay special attention to the details. When web-mapping, the metadata (data about the data) is essential to producing quality results. For the web-maps, while you will still be marked on choosing colours that are easily visible, the creative possibilities will be more limited. Recording accurate information about your layers, however, will be essential, and carry a heavy weight on your mark.
Submit the URLs to the maps you create in Moodle.
Part 1 (Map of Kamloops)
For part one, you will be downloading data from the city of Kamloops (at least 2 layers). Some potential ideas would be (though don’t feel limited to these, if you have another map you would like to make)
- Parks and Trails
- Water Network, Sewage System, and Telephone lines
- 200 year flood plane, and cadestral lots
- Download your desired layers
- From ArcGIS Pro, share your layers to the UNBC ArcGIS Portal, your data must have the a proper title, the tags: Kamloops, 2023, and GEOG205; as well as a summary of what the data is. change the Data and Layer Type to “Feature” to keep the symbology editable.
3. After your layers have been published, you will be able to see them in ArcGIS Pro in the Portal Tab of Arc Catalog. You will want to remove from your project the layers you downloaded, and re-add to your project layers from the Portal. This will avoid needing to re-upload the data when you publish your map.
4. Set the symbology and zoom to the extent you would like users to see when they open your map.
5. Publish your web map. Again your data must have the tags: Kamloops, 2023, and GEOG205; fill out as much of the metadata as you can.
6. Test the URL, and make sure the map works as expected before submitting the URL.
Part 2 (Map of Earthquakes in Peru)
Using the webpage https://arc.gis.unbc.ca/portal/home/ make a map showing the earthquakes in Peru.
The map should have the tags Peru, 2023, and GEOG205.
There is an example here, but do feel free to use other choices of colours, and make sure to use good metadata. It has been purposefully removed from this example: https://arc.gis.unbc.ca/portal/home/webmap/viewer.html?webmap=49bb5b132cc849ea9745b760c6820eb0&extent=-90.4938,-19.455,-58.0402,-0.9654
Your map should be symbolized on two attributes (Choose attributes, + Field for “año” and “magni_1”). Select drawing style “colour and size”, first using “año” as colour, and then magni_1 (magnitude with decimal places) as size.
Add labels for magnitude.
If you would like to round the magnitude values, under label field, select </> and use the expression below: “Round($feature[“magni_1″], 0)”. The “0” before the closing parenthesis is the number of decimals to keep.
Save, then enable Sharing of your map.