Oregon Dive Conditions Google-Maps Mashup

Purpose of the Oregon Dive Conditions Mashup:

The coast of Oregon’s weather and ocean conditions are highly variable both seasonally and daily.  This makes planning a trip to scuba dive difficult for both recreators and researchers.  The purpose of the Oregon Dive Conditions web-mashup is to combine information about dive sites along with the current oceanographic and atmospheric conditions.  Ideally, an individual looking to go scuba diving can use this map to determine if the coniditions are good enough to get all of their gear together and set off on a scuba-diving excursion.

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Data Sources for the Oregon Dive Conditions Mashup:

Three difference sources of data were used during the creation of this mashup:

1) Information about Oregon dive sites from ShoreDiving.com. This website provides the location of popular shore diving sites in Oregon and around the world. It also provides descriptions of the dive sites, tips, and directions.

2) The oceanographic data came from the National Data Buoy Center (NDBC). The mission of the National Data Buoy Center is to “provides comprehensive, reliable systems and marine observations to support the missions of the National Weather Service (NWS) and NOAA, promote public safety, and satisfy the future needs of our customers.” One of those services is a kml (keyhole markup language) file, which is the file type used to display data in Google Earth. One of the services they provide is a kml file that displays all of their marine observation assets located within oceans and water bodies throughout the world. This NOAA kml file (found at the bottom right section of the website) was used in the Oregon Dive Conditions mashup to provide oceangraphic information. The oceangranic parameters that are measured by the buoys off the Oregon coast include: air temperature, water temperature, wind speed and direction, significant wave height, dominant wave period, atmospheric pressure, and dew point.

3) The third data source used in the Oregon Dive Conditions mashup was long range reflectivity from the the National Oceanic Atmospheric Administration’s (NOAA) National Weather Service (NWS). Reflectivity is a measured to calculate precipitation, specifically it is the amount of power that is transmitted out of a weather radar device that is returned. Reflectivity is measured in dBZ, which are the values represented on the mashup. Higher dBZ values represent higher reflectivity, and therefore higher precipitation. On the Oregon Dive Condition mashup, areas where there are higher reflectivity values mean that there is most likely higher levels of precipitation in that area. For scuba diving, rain and clounds can cause the visibility while scuba diving to decrease, so including this information on the mashup helps let users know if there is rain or not approaching a dive site. The radar kmz was downloaded from the National Weather Service Radar Image site. The file can than be converted to a kml file by re-saving the downloaded kmz file as a kml file.

Step-by-step Oregon Dive Condition Google-Mashup Development

The Google-Maps API allows for open-source development of map-mashups. Users are given a wide variety of resources to develop their first map, including code with step-by-step instructions. An individual with no experience with html or javascript can use the basic codes provided through the Hello World! Google Maps example to start their own map. Many websites provide html and javascript tutorials. There are also websites with Web Publishing Technologies tutorials as well as Google-Maps API tutorials.

The first step is creating the base-map. This includes registering for the Google-Maps API Key and signing up for a Google Account. The basic map code is available in the Google-Maps API document, and the best example is the Hello World! code. It is easy to update the map-center coordinates to represent the location of a new map. An easy way to find out the latitude/longitude coordinates for an area is to find the address for the desired location and look that up using Google Earth. At the bottom of the Google Earth application will be the coordinates for the location (make sure the coordinates are in decimal degrees, since that is what Google-Maps requires in it’s html code). Here is an example of a basic map using the Google-Maps “Hello World!” example, as well as adding a point in the center of the map:

Basic map using Google-Map code

The next step is to add the points for the dive sites within Oregon. This is a relatively simple task, because it is repetative code and updating the text that goes within the infowindow. Here is an example of the basic map with the points for the dive sites:

Google-map with dive sites as points

Google also allows the developer of the map to choose what type of map is displayed. The first example showed the satellite version of the map. There are also options for the traditional road map and a terrain view.

It would be nice for the viewer to not just view the dive sites on the map, but have a list of them in a sidebar. This requires a bit more code then is given in the simple examples, because it requires not only pulling the data to display in point form on the map, but also requires pushing the information into a sidebar. The dive sites can be viewed by clicking on the sidebar, which will trigger that particular dive site’s infowindo to open in the map. Or, the map-viewer can click on a point on a map to view the infowindow for a dive site. Here is an example (without updated text) of the sidebar with a dive site selected to view the infowindow:

Sidebar with infowindow for dive site

The next step is adding the other layers. The first layer added is the NOAA observation buoys kml. The Google-maps API is great because it easily accepts live feed from kml’s and rss feeds so the data added to the map updates dynamically as the data is updated from the original source. There are many options for adding data, but adding a kml version of data is very simple. Google gives map examples for the options associated with the Google-maps API. When new to using html and javascript code, it is very helpful to view the map and then use the menubar of the web-browser, select View and then “Source” or “Page Source” to view the source code for the web page. Here is a screen shot of where to access this information:

View source code for a web-page

The kml and rss feed scode is relatively simple, and adding them to the google-map with the dive sites creates this dynamic map:

Kml layer of observation buoys added, showing dynamic infowindow.

The observation buoys also have infowindows that provide the oceanographic and some atmospheric data. The National Oceanic Atmospheric Administration’s National Data Buoy Center provided the kml file with this information.

The third data source, from the National Oceanic Atmospheric Administration’s National Weather Service, was added in the same fashion as the observation buoy information. It is another dynamic kml file added to the map. Here is the result:

Second kml layer of NOAA radar added to Google-map

Now all of the layers are on the map. However, the map as it is current is difficult to interpret and understand the purpose of the map. Also, the radar layer can take over the whole map when there is a lot of rain, so turning the layers on and off for easier viewing is necessary. Using basic html, the whole site can be updated to include a title, description, and basic instructions for using the map. With a little more advanced code, toggle buttons can be added to the map to allow a user of the map to turn the layers on and off. Here is the result (notice how the radar layer is not displayed on this map):

Example of toggle buttons on Google-map

Updating the header, adding a title, description, and instructions results in the final Oregon Dive Condition Google-Mashup:

Final Oregon Dive Conditions Mashup

Thanks Google for developing such a great platform for developing Google-map-mashups!

Discussion of Oregon Dive Conditions Google-Map Mashup:

The Oregon Dive Conditions Google-Map Mashup is a good place to begin to look to see if the conditions for diving along the Oregon coast will be good for a persons next dive trip. The oceanographic and atmospheric information, radar map, and dive site descriptions provide a great one-stop snapshot of what the conditions are for scuba diving. However, this map is a place to start to discover this information, and should not always be used for the final decision-making tool for whether or not a person should go diving. Contacting local dive shops, the experts, is one of the best way to understand local conditions, and in particular the nuances of each dive site. Propper training, certification, and equipment for scuba diving is always required. Not SCUBA certified? Both Professional Association of Diving Instructors (PADI) and Scuba Schools International (SSI) provide great training and certification options.

Other considerations to make when determining whether or not to go diving are beach water quality as well the tide level for when you are planning to go diving. These sources did not have easy to access to their data in the format to include in the mashup. Ideally, data displayed in the mashup will appear within the map, and will not require the user to leave the map site to view the information desired.

The Oregon Dive Conditions Google-Map Mashup provides a snapshot of the current state of the Oregon coast for shore diving. Go ahead! Check out the mashup, grab your dive gear, and go enjoy a scuba diving adventure on the Oregon coast!

Advertisements

Posted March 16, 2011 by shermkat in Uncategorized

%d bloggers like this: