2007-06-01: DataFed-GoogleEarth Mashup
From Datafedwiki
<Back to Task List | Create New Task | Edit with Form
Title: DataFed-GoogleEarth Mashup
Date: 2007/6/01
For User: MarkK
Status: InProgress
About Project or Tool: {{{about}}} (Add New project or tool)
Objective: [[:{{{Objective}}}]] (Add New Objective)
Back to DataFed Development Events
Contents |
[edit] News
- January 2, 08: An effort to organize everything that was done over the summer has begun. Unfortunately, the kml files that were posted on the CAPITA server do not open. After this has been taken care of, the files should be placed in a folder that will be linked to from this page. Afterwards, refining the GE interface should be addressed.
- June 25, 07: Focus on the use of XML styles to manipulate XML docs.
- June 22, 07: Expanded masterplan for formally linking DataFed Map views to GoogleEarth (with XML messages, see pic below)
- June 20, 07: The DataFed mapview now has a button that exports the current mapview to GoogleEarth. This feature of datafed.net is currently limited in its capabilities and is in process of expansion and development.
[edit] DataFed-DataSpaces-GoogleEarth Mashup
[edit] KML Experiments
[edit] Description of Files
| 0705_GASmoke: Gives many different Data Sets on a fire in Georgia by using ground overlays on the affected region. Each different dataset has its own radio folder and has an "off" selection if the particular dataset does not want to be seen. No pictures will be displayed upon opening the file to avoid overlap of the different datasets. | |
| 2ndGenOverlayTemplate: Creates an overlay with datafed and provider logos, all of which have editable descriptions. | |
| 3rdGenAirnow: The third iteration of overlay, with newly-formatted descriptive HTML generated from AIRNOW's Wiki RDF Feed. The provider logo has moved to the lower left, and the now-smaller datafed logo now resides above "Google" in the lower right. | |
| 4thGenOMI_AI_G: The fourth iteration of overlay, with newly-formatted descriptive HTML including datafed and provider icons generated from OMI_AI_G's Wiki RDF Feed. The provider logo has moved to the lower left and pops up a description with an icon, and the now-smaller datafed logo now resides above "Google" in the lower right and also pops up a description with an icon. | |
| AirnowData: Presents the Airnow dataset as pillars of varying heights for the measured values. The pillars are colored differently depending on how tall they are. This was done using the MATLAB file AirnowData.m, and the data was read from the EXCEL file AIRNOW.xls. | |
| Airnow Overlay: The next iteration of overlay, with descriptive HTML generated from AIRNOW's RDF feed on the Wiki. | |
| Arrow: Creates an arrow from a path and a polygon. | |
| Dust_locs: Creates many placemarks in several European countries that were affected by dust. This was done using the MATLAB file Dust_locs_Auto.m, and the data was read from the EXCEL file Dust_locs.xls. | |
| Experiment: Code for placing an image over a region. GoogleEarth automatically zooms in on the picture. | |
| Flight: Creates pillars of varying heights from Chicago to Hawaii. Also, a path outlines the pillars. This was done using the MATLAB file Flight.m. | |
| Formula100000: Three images in one file with varying transparencies. Two images are overlapped and can be selected for viewing in the GoogleEarth sidebar. | |
| G5FCSTData: Presents the G5FCST dataset as polygons of varying heights and colors for the measured values. This was done using the MATLAB file G5FCSTData.m, and the data was read from the EXCEL file G5FCST.xls. | |
| Georgia Fire Animation: Similar to the 0705_GASmoke file, but offers a time slider to go through each picture and a play button that presents each picture within the time interval. | |
| GoogleEarth: Places an image over a region and has a screen overlay which displays a logo. Also, uses the LookAt function, forcing GoogleEarth to zoom in on a specific point on earth when the file is loaded. | |
| Helix: Creates a helix in 3D. This was done using the MATLAB file Helix.m. | |
| KML Batch: A KMZ file containing five different KML files. Each KML file contains a different dataset for the same day and is enriched with metadata from each dataset's wiki page, provider logos, and the DataFed logo. | |
| Map: Displays DataFed logo in the corner of the screen. | |
| Pillar: Creates one pillar. | |
| Placemark: Creates placemarks in different locations. Each placemark has a custom icon and is linked to the other placemarks. Default placemark is a thumbtack. | |
| PlacemarksinFolders: Puts many placemarks in the different types of folders that can be made in GoogleEarth. | |
| Point: This is a file that uses a network link. It is directly linked to the file Pillar and will refresh itself every four seconds. Anything that changes in Pillar.kml will show in this file. | |
| Point Data Template: Creates samples of the different placemarks that a person can create and the different properties each placemark can have. | |
| PrettyHelix: Creates a helix in 3D with lines extending from the ground to each data point. Each data point has a description of its latitude, longitude, and altitude. The description uses some HTML. There is also an extra folder that flys around the helix when it is selected for a tour. This was done using the MATLAB file PrettyHelix.m. | |
| Random: Displays one thousand random (within a certain range) data points in 3D space. When a tour is selected for these data points, the camera does not zoom in directly on the point. The camera looks at the point from a much greater distance and tilts the camera for a better view. This was done using the MATLAB file RandomPoints.m. | |
| RandomAnimate: Creates an animation of random points dispersing from a concentrated point. This was done using the MATLAB file RandomAnimate.m. | |
| TwoArrows2: Creates two arrows at an altitude using one polygon. | |
| KML_Samples: Examples of KML code by Google. |
[edit] KML Presentations
These are some presentations that give information about specific global events
[edit] 2007 GEOSS Demo in Barcelona
| 050318 - 050322 Dust. A collection of data monitoring an African dust storm in March 2005. | |
| 070520 - 070530 Model. A collection of models that predicted the position of an African dust storm in March 2005 from day to day. |
[edit] 2007 ESIP Meeting in Wisconsin
| Georga Fire Data. A collection of data of the atmospheric conditions in Georgia during a fire in May 2005. | |
| OMI NO2 avgM. A weekly, monthly, and yearly log of NO2 concentrations in the US using the OMI dataset. |
[edit] GoogleEarth Embedded WebPage API
These are demos of useful products using the GoogleEarth API
key fields: googleearth plugin kml Demo
Delicious/rhusar/googleearth plugin kml Demo
- Earth Pad - Untitled
- Google Earth API - Camera/LookAt Viewer
- Google Earth API Samples - YouTube Embed (HTML String) Balloons
- Google Earth API Samples - JavaScript from within a Balloon
- Google Earth API Samples - frameend Event (Smooth Animation)
- Google Earth API Samples - Drag & Drop Placemarks
- Google Earth API Samples - Screen Overlay
- Google Earth API Samples - Screen Overlay (Frame)
- Google Earth API Samples - Creating Polygons
- Google Earth API Samples - Polygon Styling
- Google Earth API Samples - Creating Circle Polygons (using LinearRing)
- Google Earth API Samples - Styling Placemarks using StyleMaps
- Google Earth API Samples - Creating Placemarks
- Google Earth API Samples - Creating NetworkLinks
- Google Earth API Samples - Show/Hide Navigation Controls
[edit] Educational KML Files
These are KML files that can be used as reference. They either show very basic markup for using the many different functions in GoogleEarth or demonstrate how the different functions can be used.
- TwoArrows2.kml
Creates two arrows at an altitude using one polygon. - RandomAnimate.kml
Creates an animation of random points dispersing from a concentrated point. This was done using the MATLAB file RandomAnimate.m (http://capita.wustl.edu/CAPITA/capitareports/070601_GoogleEarth/RandomAnimate.m) - Random.kml
Displays one thousand random (within a certain range) data points in 3D space. When a point is selected, The camera looks at each point from a much greater distance and tilts the camera for a better view. This was done using the MATLAB file RandomPoints.m - PrettyHelix.kml
Creates a helix in 3D with lines extending from the ground to each data point. Each data point has a description of its latitude, longitude, and altitude. The description uses some HTML. There is also a tour that flies around the helix. - Weekly Image Template.kmz
A template kmz file that outlines what is needed to make an animation for a weekly dataset. Images for the days of the week are included for screenoverlays. - Monthly Image Template.kmz
A template kmz file that outlines what is needed to make an animation for a monthly dataset. Images for the months are included for screenoverlays. - KML_Samples.kml
Examples of KML code by Google. - NetworkLink.kml
This is a file that uses a network link. It is directly linked to the file Pillar and will refresh itself every four seconds. Anything that changes in Pillar.kml will show in this file. - Point Data Template.kml
Creates samples of the different placemarks that a person can create and the different properties each placemark can have. - Placemarks in Folders.kml
Puts many placemarks in the different types of folders that can be made in GoogleEarth. - Placemark.kml
Creates placemarks in different locations. Each placemark has a custom icon and is linked to the other placemarks. Default placemark is a thumbtack. - Pillar.kml
Creates one pillar. - ScreenOverlay_Sample.kml
Displays DataFed logo in the corner of the screen. - Helix.kml
Creates a helix in 3D. This was done using the MATLAB file Helix.m (http://capita.wustl.edu/CAPITA/capitareports/070601_GoogleEarth/Helix.m) - GoogleEarth.kml
Places an image over a region and has a screen overlay which displays a logo. Also, uses the LookAt function, forcing GoogleEarth to zoom in on a specific point on earth when the file is loaded.
[edit] Presentation KML Files
These are KML files that have been submitted to different conferences.
- GlobChem.kmz
Global Atmospheric Chemistry Console - Google Earth - Ga-Fl Smoke Event
Georgia/Florida Smoke Event May 2007 - Southern California Smoke Event
KMZ for Souther CA Smoke, October 2007 - GRAY_RRT.kmz
A collection of datasets that show environmental conditions for November 1, 2007 for the US. - GRAY_GRT2.kmz
A collection of datasets that show environmental conditions for November 1, 2007 for the world. - OMI_NO2_avgM.kmz
A weekly, monthly, and yearly log of NO2 concentrations in the US using the OMI dataset. Submitted to the 2007 ESIP Meeting in Wisconsin. - GeorgiaFireData_ESIPM2.kmz
A collection of data of the atmospheric conditions in Georgia during a fire in May 2005. Submitted to the 2007 ESIP Meeting in Wisconsin. - 070520_070530 Model.kmz
A collection of models that predicted the position of an African dust storm in March 2005 from day to day. Submitted to the 2007 GEOSS Demo in Barcelona. - 050318_050322 Dust.kmz
A collection of data monitoring an African dust storm in March 2005. Submitted to the 2007 GEOSS Demo in Barcelona.
[edit] In Progress
A window (now considered to be the user interface of a self-standing application) should pop up with many features to adjust when someone clicks on the GoogleEarth button in the Viewer Service. A table has been made of the many features that the window should have.
A metadata template form, image template form, and point template form has been made for the pop up window for the Viewer Service. This will eventually need to contain all of the fields necessary to generate a .kml which contains information from both the provider (a la datafed.net) and the Wiki.
A Metadata form with a preview generator has been made. This will be used as an intermediate step between the DataFed Viewer and GoogleEarth.
Some useful links for learning how to link this window to the services:
- http://www.w3.org/TR/xslt
- http://en.wikipedia.org/wiki/XSL_Transformations
- http://www.w3schools.com/xsl/xsl_transformation.asp
- http://www.altova.com/products/xmlspy/xsl_xslt_editor.html - A possible editor to use
[edit] Findings
[edit] XML/XSL
XSL has the ability to read an XML file and transform it into other types of files, such as HTML and other XML files. XSL files can read multiple XML files at one time, meaning one XSL file can transform multiple XML files into a document. The XSL can be run on the server or the client. In the case of the server running the XSL, ASP code is recommended. In the case of the client running the XSL, Javascript is recommended. The beauty of loading these XML files on a client or server is the XML files do not have to point to an XSL file to run them. This presents the possibility of an XML file being run by multiple XSL files from different locations.
How does this help linking the Viewer Service and DataFed Wiki with GoogleEarth? If the Viewer Service Data were in XML form, that XML file and the RDF feed from the wiki page of each dataset could be loaded on the client or server and could create a KML file from the data provided.
[edit] KML
KML recognizes some HTML! This is helpful for descriptions of pictures or placemarks, and will be the primary method of introducing data from the Wiki into GoogleEarth. Any HTML should be surrounded by <![CDATA[text here]]>. Additional help with KML format can be found at the KML website
[edit] Plotting Data
Plotting data on GoogleEarth is easiest when used with another program. MATLAB or Python can be used to print data to a KML file. With for loops, forty or fifty lines of code in another program can generate thousands of lines on a KML file.
[edit] Flyby/Flyaround
The goal was to automate a flyaround view of data loaded into GoogleEarth. Unfortunately, this cannot be automated with GoogleEarth. The closest to automating a flyaround view is to play a tour on a separate folder, which is more inconvenient than manually flying around the data.
[edit] 3D Objects
You can place 3D objects on GoogleEarth using the Model command. Unfortunately, you must first find or make a 3D model and then you can place it wherever you want.
[edit] Lines
You can make lines by using the Placemark and LineString commands. Specify the lon, lat, and alt and your path is made. Placemark is a good example of how to make a line. If your line or path is very long, make sure to use tessellate, so the path follows the curvature of the earth.
[edit] Pillars
You can make pillars by using the Placemark and Polygon commands. Flight and Pillar are examples of how to make pillars.
[edit] Custom Icons
You can make your own icons for different locations. You can even make a different icon appear when your mouse hovers over the place. Placemark is a good example of how to make a custom icon.
[edit] Time
Time can be specified using the <TimeStamp> and <TimeSpan> commands in the KML files. TimeStamp refers to one instance in time when an even happened, while TimeSpan refers to an interval of time that an event occurred. Google Earth automatically determines the duration and level of detail shown in the time slider at the top of the window based on how the time is entered. [RandomAnimate] and [Georgia Fire Animation] are good examples of using time.
[edit] Animation
The question was posed whether an animation (i.e. time-ordered series of overlays) could be set to "atuo-play" upon opening. Unfortunately, there is no such command currently in the kml language, and so the play button must be pressed to begin each animation.
[edit] altitudeMode
altitudeMode is a child of the placemark command and cannot be included in the style command.
[edit] Rectangles vs. Placemarks
Placemarks remain the same size regardless of the distance from the ground they are viewed. Rectangles cover a set latitude and longitude, so they will get bigger as the view from the ground changes.
[edit] Arrows
There are several ways to draw an arrow in GoogleEarth. Arrow draws an arrow with a line and a polygon, while TwoArrows2 draws one with one polygon.
[edit] Color
From http://code.google.com/apis/kml/documentation/kml_tags_21.html#color:
Color and opacity (alpha) values are expressed in hexadecimal notation. The range of values for any one color is 0 to 255 (00 to ff). For alpha, 00 is fully transparent and ff is fully opaque. The order of expression is aabbggrr, where aa=alpha (00 to ff); bb=blue (00 to ff); gg=green (00 to ff); rr=red (00 to ff). For example, if you want to apply a blue color with 50 percent opacity to an overlay, you would specify the following: <color>7fff0000</color>, where alpha=0x7f, blue=0xff, green=0x00, and red=0x00.
[edit] Screen Overlays
Overlays on the GoogleEarth screen (currently) are not clickable. Therefore, all additional information (i.e. metadata which appears in the <description> tags of a .kml file) has to be accessed from the places pane in the center left side of Google Earth application window.
[edit] YouTube Test
[edit] Links
Any links tagged on del.icio.us as GoogleEarth, DataFed, and mashup will show up in this list.
[edit] Other Links
KML Website. KML Reference
Link to AIRNOW RDF for use in kml generator app development. http://datafedwiki.wustl.edu/index.php/Special:ExportRDF/AIRNOW
[edit] Google Earth Resources
- Google Earth API - Much discussion surrounded the API, ability to use GE in Windows browser, Javascript on top of GE.
- KML Documenation
- Submit KML to Google, i.e. appear in Gallery
- Regionator | examples - Use hierarchical network links to go from coarse images to fine resolution as you zoom in
- Google Code KML Projects
- My Maps One easy way to find and create KML, could think of using similar interface.
- Google Gears
- ESDWG 17th Earth Science Data Systems Working Group Meeting
- Datafed-Google Earth Mashup
- GE Science App Meeting
| About | [Oops! “{{{about}}}” is not in the list of possible values (DataFed, Browser, Catalog, AQ uFIND, CATT, EE, Metadata, Data Access, Other) for this attribute] |
| Date | 1 June 2007 + |
| Status | InProgress + |
| TaskTitle | DataFed-GoogleEarth Mashup + |
| User | MarkK + |
Categories: Task | DevEvents | Atomic | 070601 | MarkK | InProgress | GoogleEarth | Collaboration
