3. 17September2008
UniversityofCalifornia,SantaBarbara-WebStandardsGroup
Mission:
To facilitate the integration of spatial thinking into processes for
learning and discovery in the natural, social, and behavioral
sciences, to promote excellence in engineering and applied
sciences, and to enhance creativity in the arts and humanities.
Engagement:
Hosting events (brownbags, workshops, lectures)
Developing spatial analytic tools
Offering a help desk
Assisting with research proposal development
Image Source: NAIP, 2005
7. 17September2008
UniversityofCalifornia,SantaBarbara-WebStandardsGroup
“…it would behove spatial scientists to articulate to
the broader research community the potential of
recording and making accessible spatial data in the
appropriate formats — and the painlessness of the
process.”
A place for everything:
More researchers must record the latitude and longitude of their data.
Editorial: Nature 453, 2 (1 May 2008)
8. 17September2008
UniversityofCalifornia,SantaBarbara-WebStandardsGroup
Spatial Data at the University
Research
data analysis and results dissemination
Classroom
office locations, events, classrooms, miscellaneous
directions, instructional projects
Infrastructure
maps, blueprints, streets, buildings, images, crisis
management, physical resources, natural resources,
office and classrooms, fleet management, planning,
operational support, registrar and personnel
databases
Student
data on personal websites, often integrated with third
party applications and data
9. NASA World Wind (client and server)
OpenLayers (client)
MapServer (server)
Geoserver (server)
GDAL/OGR (server-based geo-database toolkit)
GRASS (full desktop GIS client)
Google Earth (client)
Google Maps (client)
Microsoft Virtual Earth (client)
ArcGIS Explorer (client)
MapQuest (client)
Google Earth Enterprise (server)
ArcGIS (full desktop GIS client)
ArcGIS Server (server)
deCarta (server)
AutoDesk AutoCad (client)
AutoDesk ProductStream (server)
Oracle Spatial (server)
17September2008
UniversityofCalifornia,SantaBarbara-WebStandardsGroup Sample Software
FreeOpenSourceProprietary
10. • ESRI shapefile (.shp)
• KeyHole Markup Language (.kml)
• GeoRSS (.rss, .xml)
• AutoCad DXF (.dxf)
• Census TIGER
• ESRI Coverage
• ESRI Personal Geodatabase
• GeoTIFF
• Digital Raster Graphic (DRG)
• Digital Elevation Model (DEM)
• Spatial Data Transfer Standard (SDTS)
• Image formats like jpg, tiff, gif, and png (often served via a WMS operation)
Considerations when choosing a file type for spatial data:
What software support it? What does your consumer want? Is it fast? What
type of data, complexity, and dynamics can it support? How easy is it to
autogenerate and update (from your database to the new file format)? How
well will it age?
17September2008
UniversityofCalifornia,SantaBarbara-WebStandardsGroup Example Geographic File Types
11. 17September2008
UniversityofCalifornia,SantaBarbara-WebStandardsGroup
Keyhole Markup Language (KML)
Keyhole Markup Language (KML) is an open source XML-based
specification for expressing geographic data.
Developed as a Google Earth file format to represent
georeferenced points, polylines, polygons, and images
KML has become widely supported by many other software
applications and online mapping services.
Core data within a KML document include longitude, latitude,
elevation, and name descriptions
A sizable number of advanced specifications also exist, including
tags for cartographic customization, viewer position, time, and
iterative data refresh calls.
12. 17September2008
UniversityofCalifornia,SantaBarbara-WebStandardsGroup
HelloWorld.kml
<?xml version="1.0" encoding="UTF-8"?>
<kml xmlns="http://earth.google.com/kml/2.2">
<Document>
<name>HelloWorld1.kml</name>
<Placemark>
<name>Transformers</name>
<description>There are some transformers here.</description>
<Point>
<coordinates>
-119.8512453552352,34.41944355498201,0
</coordinates>
</Point>
</Placemark>
</Document>
</kml>
Something to notice
If the first letter of a tag is upper
case, it can hold child elements. If
the first letter is lower case, it
denotes a simple element—one
that has no possible children.
26. 17September2008
UniversityofCalifornia,SantaBarbara-WebStandardsGroup
StylingandCartography
Using the CDATA Element
If you want to write standard HTML inside a <description> tag, you can
put it inside a CDATA tag. If you don't, the angle brackets need to be
written as entity references to prevent Google Earth from parsing the
HTML incorrectly (for example, the symbol > is written as > and the
symbol < is written as <). This is a standard feature of XML and is not
unique to Google Earth.
Source: http://code.google.com/apis/kml/documentation/kml_tut.html
<description>
<![CDATA[
<h1>CDATA Tags are useful!</h1>
<p><font color="red">
Text is <i>more readable</i>
and <b>easier to write</b>
when you can avoid using entity
references.</font></p>
]]>
</description>
<description>
<h1>Entity references are hard
to type!</h1> <p><font
color="green">Text is
<i>more readable</i> and
<b>easier to write</b>
when you can avoid using entity
references.</font></p>
</description>
32. 17September2008
UniversityofCalifornia,SantaBarbara-WebStandardsGroup
DynamicKML
Network Link Example
<?xml version="1.0" encoding="UTF-8"?>
<kml xmlns="http://www.opengis.net/kml/2.2">
<Folder>
<name>Network Links</name>
<visibility>0</visibility>
<open>0</open>
<description>Network link example 1</description>
<NetworkLink>
<name>Random Placemark</name>
<visibility>0</visibility>
<open>0</open>
<description>A simple server-side script that generates a new random
placemark on each call
</description>
<refreshVisibility>0</refreshVisibility>
<flyToView>0</flyToView>
<Link>
<href>http://nanocarta.com/tools/randomsphere.php?sample=100</href>
<refreshMode>onInterval</refreshMode>
<refreshInterval>5</refreshInterval>
</Link>
</NetworkLink>
</Folder>
</kml>
41. 17September2008
UniversityofCalifornia,SantaBarbara-WebStandardsGroup Distribution and Sharing
A) Delivery of raw or auto-assembled KML
KML file is shared via a website, email, or disk
User loads KML into the Google Earth application
B) Delivery of KML from Google Maps
KML is hosted
Google Maps renders KML
C) Delivery of KML with the Google Earth browser plug-in
Webpage created using Google Earth API
Hosted KML is rendered within Google Earth frame
D) Delivery with desktop applications like ArcGIS Explorer,
Virtual Earth, NASA World Wind, etc.
Generally similar to standalone KML (option A)
E) Mediator web service
Website service allows user collaboration, provides
hosting, and file index or discovery mechanism.
Examples: Google MyMaps, Flickr, Platial , Facebook,
Yahoo! FireEagle
(Note: some of these overlap and/or could be combined)
42. 17September2008
UniversityofCalifornia,SantaBarbara-WebStandardsGroup Distribution and Sharing
F) Server-based delivery
Application and data are hosted. Interface may be
public or, in some cases, secured. Examples: Google
Earth Enterprise, OpenLayers, ArcGIS Server
G) Enterprise relational database manager
Typically for intranet-type usage. Manages multiple user
collaboration, conflicts, and versioning
Oracle Spatial, ArcSDE
H) Search engine discovery of spatial data (an emerging case);
programmatic structured query using various sites’ APIs.
Application launches as defined by user or OS (assisted
by properly configured MIME type). Examples: Google
Search, Yahoo! Pipes, Microsoft Popfly
(Note: some of these overlap and/or could be combined)
44. 17September2008
UniversityofCalifornia,SantaBarbara-WebStandardsGroup
Query
Geocoding
The process of assigning geographic coordinates to a
map feature, description, or address.
Input: Address or location description
Examples: Goleta, CA; 90210; New Zealand
World Trade Center, downtown Los Angeles
Output: Geographic Coordinates
45.2342W, 15.2346N, 1000m asl, WGS84
There are many complicating factors to geocoding.
For example: the grammar of the input, positional
accuracy / vagueness / scale, places with the same
name, foreign languages, deprecated names, new
names, misspellings, etc.
45. 17September2008
UniversityofCalifornia,SantaBarbara-WebStandardsGroup
Query
Geocoding
Despite the problems, geocoding is at the core of
many web-based mapping applications.
KML offers the <address> element as an alternative
to coordinates. Google Earth and Google Maps will
attempt to geocode the address and render the
position. Usability will largely depend on the input
address and the intended application.
For example, the following KML uses the street
address of a UCSB electrical transformer station
(shown in the middle left of the screen; geocoded
address is on the bottom right).
Note: In Google Earth and Maps, if a <Point> tag is provided in the
KML also, it will take precedence over an <address>.
48. Routing and
Service Area
Routing implementations
remain largely proprietary,
though some open source
options are beginning to
emerge.
The Google Maps API offers
access to driving directions.
Proprietary web services are
plentiful.
ArcGIS Server offers routing
functionality.
Image source: ArcGIS Network Analyst, esri.com
17September2008
UniversityofCalifornia,SantaBarbara-WebStandardsGroup
49. 17September2008
UniversityofCalifornia,SantaBarbara-WebStandardsGroup
Query:AnalysisResources
Google Earth Developers
Interact with other developers and explore their work.
(http://groups.google.com/group/kml-support)
ArcGIS Explorer
Proprietary virtual globe with analysis functionality, particularly
when coupled with other ESRI products. Note: UCSB has an
ArcGIS site license. (esri.com)
Yahoo! Pipes
Graphical multistep web query that includes spatial data.
(pipes.yahoo.com)
Microsoft Popfly
Graphical multistep web query that includes spatial data.
(popfly.com)
OpenLayers
Javascript slippy map library with a gallery of numerous web
applications. (openlayers.org)
GIS.com
A “paleo” introduction to geographic information and analysis
52. 17September2008
UniversityofCalifornia,SantaBarbara-WebStandardsGroup
PolicyandBestPractices The Policy Landscape
No homogenous body of geographic data web standards
or regulations exist. So far, emerging precedents are
largely arising from privacy and intellectual property law.
Private enterprise is also gauging consumer reaction and
trying to maximize utility, create monetization potential,
and not alienate users.
Accessibility
Suggested Design Practices
Locational Privacy
54. 17September2008
UniversityofCalifornia,SantaBarbara-WebStandardsGroup Accessibility
Provide a text description of the map’s or data’s purpose.
Provide descriptions of any included, integrated multimedia.
Use clear, descriptive names and labels.
Consider appropriate colors and contrast for people with color
discernment difficulties or other visual impairment
Cite data sources; allowing users to investigate other mechanisms for
its visualization
In technology selection, consider open 3D rendering formats. For
instance, OpenGL calls to a graphics card can be captured and
manipulated. Haptic feedback devices can more readily interpret the
data.
Ensure links are simple, visible, and exposed (no hidden image links)
Be very cautious about rapid blinking and dynamic data refreshes.
Provide warnings as necessary to assist epileptic population.
PolicyandBestPractices
55. 17September2008
UniversityofCalifornia,SantaBarbara-WebStandardsGroup Best Practices
Validate your KML
Use spaces and indentions even when the KML is
automatically generated (when text editing, be
careful for hidden characters)
Comment within the KML when something is not
obvious (like with network links)
Generally, do not use KML as the database (usually
better as a result of a database). Use KML to
describe the geographic elements of a database.
Also, consider that most software limits renderable
geometry
When hosting, use .htaccess to create MIME
associations for KML and KMZ to Google Earth.
PolicyandBestPractices
56. 17September2008
UniversityofCalifornia,SantaBarbara-WebStandardsGroup Best Practices
Use GeoRSS to syndicate geographic data (refer to
KML). HTML:RSS::KML:GeoRSS
Maximize link confidence (hide awkward script
calls; links to external resources should be reliable;
make sure the external resource acts like you think
it should).
Provide usage information and instructions for
complex data
Use object identifiers in KML. It will maximize users’
ability to search and access subunits of the data.
Provide data authorship credit (also affords author
responsibility).
PolicyandBestPractices
57. 17September2008
UniversityofCalifornia,SantaBarbara-WebStandardsGroup Best Practices
Consider window viewing sizes (large images and
long descriptions can take over an entire
viewscreen).
Allow users control and navigation of layers.
Consider file size, number of points, complexity
(warn as necessary). For instance, use Regionator
to manage large image overlays
Minimize the distraction of legends or screen
overlays.
Do not use the awful (thankfully sparsely
documented) blink style in KML.
Cache geocodes
PolicyandBestPractices
58. 17September2008
UniversityofCalifornia,SantaBarbara-WebStandardsGroup
PolicyandBestPractices
Right to privacy varies greatly by jurisdiction. The
California Constitution, Article 1, Section 1,
describes privacy as an inalienable right.
Spatial and temporal data resolution is a key
component with respect to invasion of privacy.
For example, spatially aggregated U.S. Census
data are available soon after compilation.
Individual Census responses are prohibited from
release for 72 years.
Aggregating multiple individuals’ personal
information is considered less invasive than
individually identifiable information.
Geographic Privacy
60. 17September2008
UniversityofCalifornia,SantaBarbara-WebStandardsGroup
PolicyandBestPractices
Always tell users what you want to do with
their location
Let users know when you are collecting their
location information
Give users control of their own data
Make sure users' data are secure
Only allow users to manage their location, but
not others
Don't be creepy
Yahoo! Fire Eagle
Developer Code of Conduct
Source: Fire Eagle Developer Code of Conduct,
http://fireeagle.yahoo.net/developer/documentation/code_of_conduct
Note: These points are paraphrased.
61. 17September2008
UniversityofCalifornia,SantaBarbara-WebStandardsGroup
PolicyandBestPractices Notice - Individuals must be informed that their data is being
collected and about how it will be used.
Choice - Individuals must have the ability to opt out of the
collection and forward transfer of the data to third parties.
Onward Transfer - Transfers of data to third parties may only occur
to other organizations that follow adequate data protection
principles.
Security - Reasonable efforts must be made to prevent loss of
collected information.
Data Integrity - Data must be relevant and reliable for the purpose
it was collected for.
Access - Individuals must be able to access information held about
them, and correct or delete it if it is inaccurate.
Enforcement - There must be effective means of enforcing these
rules.
International Safe Harbor Privacy Principles
Source: United State International Trade Administration
63. 17September2008
UniversityofCalifornia,SantaBarbara-WebStandardsGroup
The Future of Spatial Data
An evolving platform:
extending the geographic model to Eames’ and
Morrisons’ Powers of Ten
The Progression of Internet Maps Interaction:
1. view (see my house)
2. add (tag locations important to me)
3. query (get directions, see patterns)
4a. communicate (sharing and social interaction)
4b. mirror world (more realism/physics)
5. inhabit
Image Source: NAIP, 2005
64. 17September2008
UniversityofCalifornia,SantaBarbara-WebStandardsGroup
The Future of Spatial Data
Semantic Spatial Web
(spatially literate, natural language Internet)
3D Internet
(spatially visualized and inhabitable Internet. Virtual
Reality)
Augmented and Mixed Reality
(combination of real world and computer generated
data)
Digital Earth
(spatiotemporal database of everything)
Image Source: NAIP, 2005
65. • Geographic Data Basics
• Keyhole Markup Language (KML)
• Authoring KML
• Dynamic KML
• Distributing Geographic Data
• Querying Geographic Data
• Policy and Best Practices
Topics
Image Source: NAIP, 2005
17September2008
UniversityofCalifornia,SantaBarbara-WebStandardsGroup
SPATIAL DATA, KML, and the
UNIVERSITY WEB