[R-sig-Geo] Subsetting shapefile type PolyLine
Rafael Duarte
rduarte at ipimar.pt
Mon Feb 4 12:23:08 CET 2008
Dear all,
I am very new to SIG.
This is probably a very simple question but I could not find an answer
searching the web and the R-SIG emails archive.
I have an ESRI shapefile with a coast and bathymetric lines. In the dbf
file I have a column “ELEVATION” that gives this information.
I import the shapefile with:
require(maptools)
teste2 <- read.shape("bat_lin")
Shapefile type: PolyLine, (3), # of Shapes: 981
Now I plot this information:
plot(teste2)
But my problem is that I want to plot a subset of bathymetric lines:
ELEVATION = 100, for example.
I tried to follow the example given in maptools: subset.
I tried to use functions: Map2lines.
But I could not find a solution to plot only a subset of bathymetric lines.
Many thanks for any help.
Rafael
--
Rafael Duarte
Marine Resources Department - DRM
IPIMAR - National Research Institute for Agriculture and Fisheries
Av. Brasília, 1449-006 Lisbon - Portugal
Tel:+351 21 302 7000 Fax:+351 21 301 5948
e-mail: rduarte at ipimar.pt
More information about the R-sig-Geo
mailing list