Thursday, September 24, 2015

Geospatial Web Services

Goal and Background
The goal of this lab was for me to become comfortable with the various techniques used to host geospatial web services. I published hosted feature services via ArcGIS online by uploading both shapefiles and CSV files directly, as well as by using an ArcMap document to facilitate the upload. I published a tiled map service using ArcGIS Server, and subsequently consumed the map service in a web application. I authored a feature access service with time-enabled data and made a web map to consume the service.

Methods
In order to publish the shapefiles, I selected the shapefiles I wanted to upload in ArcCatalog and sent them to a .zip folder. I then uploaded the .zip folder using ArcGIS Online's "Add Item" button. After adding a title and tags, I published the data to ArcGIS Online as a feature service (Figure 1).

Figure 1: Shapefile to hosted feature service
Next, I created a web map using the hosted feature service I just uploaded. First, I simplified the layer names. I then adjusted the transparency of the "Counties" layer to help it fit into the background better, changed the colors and stroke width of "Highways" and "Interstates" so they would be more easily visible and differentiable, and changed "Cities" to a darker color (Figure 2). After I deemed the map "cartographically pleasing", I saved my map to ArcGIS Online.

Figure 2: Transportation web map
Next, I published data of Wisconsin fire occurrences in 2004 that was saved in a Microsoft Excel spreadsheet with XY coordinates. In order to publish this data I first saved a copy of the spreadsheet as a CSV file. I next used ArcGIS Online's "Add Item" button to import the data as points located at their XY coordinates (Figure 3).
Figure 3: CSV to Points with native attributes visible.
Upon displaying the data, I noticed that the pop-ups only showed the Object ID, Feature ID ,and X and Y coordinates of the individual points rather than show the date of the fire at the point's location (Figure 3). In order to amend this, I configured the pop-ups to only display the date of the fire at each point (Figures 4 & 5).

Figure 4: Wisconsin fire occurrences with the edited pop-up window
I published a feature service containing two vector datasets related to Wisconsin water resources. First, I added the "Rivers_and_Streams" and "Lakes" features from my class folder to a new map. I then edited the feature titles and saved the map to my personal folder as a .mxd document. Next, I connected ArcGIS Desktop to ArcGIS Online. I used ArcGIS Desktop's built-in capabilities to publish my map to ArcGIS Online as a feature service with creating, querying and updating capabilities. These capabilities will allow an end-user to add features to the feature service, update the feature service with features they've edited, or use the data within the feature service to query features. After configuring the feature's settings, title, summary, and tags, I published the map (Figure 6). The layers had superfluously redundant labels, so I renamed them with their simplified names from my ArcMap document (Figure 6). The map had unhelpful pop-ups, so I eliminated the pop-ups for the "Rivers and Streams" layer and configured the "Lakes"'s pop-ups so only the name and area in kilometers are shown (Figure 7).

Figure 5: The feature service's tags and layers' edited names. 

Figure 6: An edited pop-up for "Lakes"

After utilizing both ArcGIS Online's and ArcGIS Desktop's built-in publishing capabilities for shapefiles, .CSV's and .MXD's - I learned how to publish a tiled map service via ArcGIS Server. This first required me to connect to the department's ArcGIS server and connect to my database on the server. After connecting to my database, I imported a raster dataset from the class folder to my enterprise geodatabase (Figure 8). After configuring the symbology (Figure 9), I used ArcGIS Desktop's built-in capabilities to publish the image to my folder in the the department's ArcGIS Server (Figure 10). I enabled caching, so the map will take less bandwidth, and load faster.

Figure 9: The data's publishing settings


Figure 7: The raster data in my enterprise geodatabase
Figure 8: The raster data in ArcGIS Desktop prior to publishing

After the publishing was finalized, I navigated to the department server directory, and viewed my map service in ArcGIS Online (Figure 11).

After learning how to publish services to ArcGIS Server, I learned how to reference a service I've created, in a web map service. In order to do this, I imported two layers, "Earthquakes" and "Hurricanes" into my enterprise geodatabase (Figure 12). Next, I added the layers from my enterprise geodatabase to a new map, and saved it to my class folder. After adjusting the symbology of the layers (Figure 13), I enabled time on both layers. This allows both layers to be animated according to their temporal attributes. Next, I published the map document to the department server as a service with creating, editing, deleting, and querying capabilities (Figure 14).

Next, I opened up a blank map in ArcGIS Online. In order to add the newly-created services to a web map, I used the "Add Layer from Web" button to add the natural disaster layers merely by pasting their URL within the department server. After adding the data, I simplified the pop-ups for both classes (Figure 15), and shared my map to the department and also my course group. Next, I calibrated the time settings so the time animation will show hurricanes and earthquakes occurrences progressively; adding data to the map 6 months at a time, until all of the data is displayed (Figures 16 & 17).

Figure 10: "Earthquakes" and "Hurricanes" in my enterprise geodatabase


Results:
Figure 11: The data as it appears on ArcGIS Online
Several of the maps I generated had formatted pop-up windows, so their information is extremely easy for the end-user to interpret (Figures 4, 6, and 13). The two maps hosted on the department Server can also be viewed by anyone with the URL without costing esri credits (Figures 11 &12. The last map features time-enabled data, which allows the end-user to view both spatial and temporal trends in the data (Figures 12-15).


Raster data: Click Here
Map featuring temporal information and good pop-up windows: http://arcg.is/1L9tWEf
Figure 12: Earthquakes are symbolized as red dots, and the Hurricanes are symbolized as lines
Figure 13: A  pop-up for "Hurricanes"

Figure 14: All of the "Hurricane" lines along the Northern coast of the Gulf of Mexico

Figure 15: All of the "Earthquake" points in Alaska
Sources:
Advanced Remote Sensing Class. (2012).

Fu, Pinde (2015). Earthquake Data.
Retrived from
\\EsriPress\GTKWebGIS\Chapter3\Data.gdb\Earthquakes, courtesy of USGS National Atlas.

Fu, Pinde. (2015). Hurricane Data.
Retrived from
\\EsriPress\GTKWebGIS\Chapter3\Data.gdb\Hurricanes, courtesy of NOAA National Climatic Data Center.

Price, Maribeth. (2014). Mastering ArcGIS geodatabase.

Wilson, Cyril. (2012). unpublished data.

Wisconsin DNR. (2013).

No comments:

Post a Comment