Skip to content
Prev 7221 / 29559 Next

How to crop a shapefile ?

Hi all,

For this particular problem, Dylan Beaudette is probably exactly right.
However, I ran into problems using similar tools in OpenJump when we
wanted to create a shapefile of a region that we could postal address
geocode against (the way the boundary line segments were clipped was a
problem for the geocoder), which lead me to write tools in R to do it
(outlined in my earlier post). That code does not clip lines, rather it
enable the extraction of the original complete road segments. Since most
of the ways in OSM don't have the attribute information needed for
geocoding, the issue I was addressing won't be relevant here.

Besides GRASS (which can be a bit overwhelming at first), and OpenJump
(mentioned above), the Clip tool within the fTools plug-in for QGIS
should also work. Given the size of the OSM road network files, a
machine with a fair amount of memory will probably be needed to handle
the problem.

Dan
On Thu, 2009-12-17 at 10:27 -0800, Dylan Beaudette wrote: