blankblank blank


Archive for the 'shapefile' Category

Free Vector Country Borders, Administrative Boundaries, And Soon More

Wish I’d known about this site when I was hunting for a high-res border outline for the province of Umbria in Italy. The Global Administrative Boundaries website offers free vector GIS data for country borders and administrative areas within those borders. Data is available in geographic coordinates (lat/long), WGS84 datum, in multiple formats:

Coverage is worldwide for level 1 data (country borders), but diminishes as you go down as far as level 4 (sub-administrative units), though for the latter there are some countries for which such a data level isn’t relevant. You can see maps of current level coverage here, and missing data will likely be added in the future. Data is licensed under Creative Commons for the US; other unspecified terms may apply for the rest of the world. Here’s the Italian province of Umbria, with the best free data I could initially find plotted in purple, and the high-res GADM data in blue:

umbria

Via Slashgeo.

Just around the corner, scheduled for unveiling at the October 2009 NACIS conference, is Natural Earth Vector. While there’s some overlap with GADM at the upper boundary levels, Natural Earth Vector may not include some of the finer administrative boundaries available in the GADM . But it will have a wide variety of other geographic features not available in GADM in vector format at multiple zoom levels (list from the web post):

  • Continents (North America, Europe, Asia, etc)
  • Cultural regions (South Asia, West Africa, etc)
  • Countries (US, Canada, Mexico, etc)
  • Country sub-divisions (for the US, states, semi-independent territories, dependencies, associations)
  • Disputed territories (like Kashmir, Northern Cyprus)
  • 1st order admins (states, provs)
  • Bathymetry
  • Lakes
  • Lake Center Lines
  • Rivers (including attributes that allow easy “tapering” of drains)
  • Islands
  • Glaciers
  • Populated places (urban boundaries, not city points)
  • Cities (point locations)
  • Physical features like peaks, ranges, valleys, plains

I’ll try to post again when it’s officially released.

Via Kelso’s Corner.




Habitat Digitizer Extension For ArcGIS

Stumbled across this the other day, and while I don’t currently have the need for it (or a copy of ArcGIS to try it out on), it sounds useful enough to post about. NOAA’s Center for Coastal Monitoring and Assessment offers a free extension for ArcGIS called the Habitat Digitizer:

The Habitat Digitizer Extension is designed to use a hierarchical classification scheme to delineate habitats by visually interpreting georeferenced images such as aerial photographs, satellite images, and side scan sonar. The extension allows users to create custom classification schemes and rapidly delineate and attribute polygons, lines, and points using simple menus. The extension allows new hierarchical classification schemes to be easily created, modified, and saved for use on future mapping projects. There are several advantages to using classification schemes with a hierarchical structure including: the detail of habitat categories can be expanded or collapsed to suit user needs, the thematic accuracy of each category/hierarchical level can be determined, and additional categories can be easily added or deleted at any level of the scheme to suit user needs.

Habitat_Digitizer

While written for habitat digitization, it could prove useful for any digitization projects with extensive classification requirements. Versions are available for ArcView 3.0, ArcGIS 9.0, and ArcGIS 9.2 from the product page; download files include a PDF manual.




Convert Shapefiles Into SVG Format With Thematic Coloring

Not too long ago, I covered an online application from indiemapper that converts shapefiles into SVG format, a standard format for vector illustration programs like Adobe Illustrator or the open source Inkscape. One drawback of that site was the inability to color/shade the SVG output based on shapefile attribute data. Ken Hardy has a Perl utility called shptosvg that will take shapefiles and convert them into SVG format, and includes the ability to color files based on their attributes:

410px-Ogallala

Features (from the website):

  • Accepts source SRS specs on the command line, allowing multiple input files to have disparate coordinate systems.
  • Generates the results projected to any SRS using Geo::Proj4.
  • Works on multiple shapefiles at a single invocation, layering them in order into the SVG map.
  • Supports specification of color and other rendering options, per source file, on the command line.
  • Optionally select subset of shapes by regex on arbitrary attribute fields.
  • Support coloring of shapes by value of an attribute field.
  • Allow specification of a shapefile to use in scaling but not in rendering. That supports independent production of layers to be later combined in an SVG editor; they can all be scaled and translated according to the geometry of the base/largest layer to aid layering after the fact.

You’ll need to have Perl installed on your system; see the download page on the official Perl site for links to several different versions. And you’ll need to be comfortable working in a command-line interface; no GUI available yet. Ken has a page documenting usage, along with an example page that describes how he created the image above.

HT to Ken (of course).




MapTool Goes To Version 2– Elevations, Areas, And Distances In Google Maps

I’ve covered Zonums Software free online application MapTool before; the original version let you determine the elevation of a point in a Google Maps interface, as well as measuring the length of a multi-segment path or drawn polygon, but not much more. Zonums has recently updated this application to  MapTool 2, which adds some really nice new functions (most accessible by clicking on the Options link at top):

  • Create vertices by manually entering coordinates, in addition to previous option of clicking on map (use Input link at the top for this)
  • Continuous coordinate read-out in both latitude/longitude and UTM
  • Divide a drawn line into equal parts by automatically adding equally-spaced vertices, or add vertices with a user-defined spacing
  • Convert a drawn polygon into a polyline, and vice versa
  • Edit individual vertices in a line or polygon
  • Get a count of the total number of vertices in the drawn feature
  • Get an elevation profile for all the vertices on a line

profile

  • Determine the extents (bounding box) for the drawn feature
  • Export the vertex coordinates as a text file
  • Export the line or polygon directly as a GPX, DXF or shapefile in latitude/longitude/WGS84, with the option to include vertex elevations



LandSerf – Google Earth And GPS Functions

In previous posts, I reviewed LandSerf’s raster terrain analysis functions and vector functions. Today I’ll wrap up with a short review of LandSerf’s Google Earth and GPS functions.

Google Earth: The most notable Google Earth functionality is the ability to export vector data, either imported or generated by the program, into KML vector files. So I can open a DEM, like the sample one of Mt. Rainier included with the program:

lsdem

Generate a set of flow vectors for the DEM:

flowvectors

And then export the vector data as a KML file:

rainier

You could do something similar with a shapefile opened in LandSerf, but just be sure the shapefile is in NAD83 or WGS84. As I mention in the post on LandSerf vector functions, LandSerf has problems re-projecting from one datum to a significantly different second datum, and Google Earth data needs to be in WGS84 (NAD83 is almost the same). A search for “KML shapefile” on this blog will bring up a number of other programs that do a better job of converting shapefiles to KML, including preserving attribute data, which LandSerf doesn’t. But all of those are Windows-based; LandSerf runs on Macintosh and Linux, so it might be a useful option for those OSes.

Note: You should save vector data as a KML file; the KMZ file format is supposedly reserved for saving raster data as Google Earth image overlays, but I’ve been unsuccessful in getting that to work.

GPS: The list of useful GPS functions in LandSerf is a bit longer:

  • Convert loaded shapefiles or other vector data to GPX format (data must be in WGS84/NAD83 datum)
  • Load a GPX file as vector data, then save it in any of the vector formats LandSerf supports
  • Interface directly with a GPS. You’ll need to have the GPS connected to your computer and turned on before starting up LandSerf. To establish a connection to the GPS, use Configure=>GPS and scan for a connected unit. Once you do this, you can import waypoint data using the File=>Import from GPS function. While the dialog box gives you the option to import waypoints, tracks and routes:

gpsimport

I’ve had difficulty getting tracks to import successfully – the program just shuts down on me. This may just be an issue with my model GPS (Garmin 60Cx); f you have better luck, let me know. You can import the data in the default lat/long coordinate system. or re-project it on import to OSNG or UTM. Once there, you can export it in GPX, shapefile or other vector format.

  • You can also export point data (no lines or polygons) directly from LandSerf to a connected GPS as waypoints.

If you can get track data to import successfully from your GPS to LandSerf, which I couldn’t, there are several other functions that might prove useful:

  • On importing the data, you have the option of saving all the track data in spreadsheet format with position, elevation and time
  • As with other vector data, if you have a digital elevation model loaded in the program, you can get a elevation profile plot; see this previous LandSerf post for more info
  • If you have a GPS track that is broken into .segments because you lost the GPS signal, LandSerf has the ability to join all of the line segments into a single line, which you can then save as a GPX track file, using the Edit => Join vector lines function. AFAIK, it’s the only free program that can do this.

As with the Google Earth functions, there are other programs that can do most of this in Windows, but far fewer free options in Macintosh and Linux.




Convert/Reproject Shapefiles And KML Files To SVG Format With indiemapper

indiemapper is a promising-looking thematic mapping service that is supposed to come online shortly. But until then, they’ve released a free  online Flash application that lets you upload vector data (point, line or polygon) in KML or shapefile format, re-project it into one of 11 different projections …

  • Equirectangular
  • Mercator
  • Winkel Tripel
  • Robinson
  • Albers Equal Area Conic
  • Lambert Conformal Conic
  • Orthographic
  • Polyconic
  • Sinusoidal
  • Bonne
  • Cylindrical Equal Area

… and then export it as an Scalable Vector Graphic (SVG) file for use in programs like Adobe Illustrator or Inkscape. Shapefiles must be in geographic coordinates (latitude/longitude), WGS84; KML files are already in this format. Network KML files are acceptable. Add a file to the display, or choose one or more of their sample datasets:

open

You can load multiple datasets into the display, move their draw order, and turn them on and off  by clicking on the “eye” icon:

datalayers

The graticule grid can be turned on and off, and spacing set to automatic or manual.

Select the projection using the “Project” button at upper-right:

projections

You’ll get info about the projection, including its pluses and minuses. Here’s Mercator (a screen capture, not SVG):

mercator

And Albers Equal Area Conic:

albers

With the center latitude/longitude of view adjustable. Once done, click on the “Export” button at upper right to convert the vector data to SVG format, and download it to your computer for use in vector editing software, or for viewing in a compatible browser like Firefox.

There are limitations for now. There’s no control over layer colors, and no thematic coloring based on the attributes of the vector files. It looks like the full indiemapper application will have those, and the screenshots make it look interesting, but it’s not clear yet whether that full online app will have a free version. Stay tuned.

Via the thematic mapping blog.




LandSerf – Vector Functions

In a previous post, I gave a random overview of LandSerf’s strong terrain analysis functionality. But it  has some some useful vector functions as well, some derived from or related to raster elevation data, others more general. I won’t talk about the general vector data creation functions here; they’re perfectly fine, but lots of free GIS program can do that; instead, I’ll just highlight a few of the more distinctive vector functions that aren’t as common. Note: Save the derived vector data if you want to keep it; LandSerf doesn’t save created, modified or derived datasets automatically.

Continue reading ‘LandSerf – Vector Functions’




Convert TIGER Census Shapefiles (And General Shapefiles As Well) Into Thematic Google Earth KML Files

Bruce Ralston of the University of Tennessee has previously released several US Census TIGER data tools that I’ve posted about in the past. TGR2SHP converts TIGER files into shapefile format, while TGR2KML converts TIGER polygon files (like legislative districts and county subdivisions) into basic KML files for viewing in Google Earth. Both of these tools only work with the older pre-2007 TIGER format, which is no longer in use; the Census Bureau now issues all this TIGER data in standard shapefile format. But Bruce Ralston has just released a new tool called AFF Mapper that goes a step beyond his previous ones: it can convert TIGER shapefile data into KML format, link it to tabular American Fact Finder data (AFF) from the US Census, and plot this census data thematically. But unlike the previous TIGER tools, this one is a general-purpose one; it can convert any shapefile – point, line or polygon – into a thematic or unique value KML file, with the option of using thematic data from a linked external table. The only limitation is that the shapefile must be in geographic coordinates (lat/long), WGS84 datum, Google Earth’s native coordinate system.

I won’t go through the process with Census data; there’s an excellent PDF manual that describes the process of creating maps like this one (from the manual):

Continue reading ‘Convert TIGER Census Shapefiles (And General Shapefiles As Well) Into Thematic Google Earth KML Files’