Message-ID: <CAM98pTxnPQ4_o1yJ_ATPeOeNoC2TmEyFrp5THCFYoUhbU60Gpg@mail.gmail.com>
Date: 2019-11-10T18:55:03Z
From: Caridad Serrano Ortega
Subject: It's possible delimit a shapefile very extent using R? (Roger Bivand)
Hi Rober,
My script with R is intermedi level and the english is basic one. Is this
your answer?
pas_file<- readOGR("D:/DATOS", "CoveredArea")
pas_file at bbox # Extend all
pas_file at polygons[[1]]@Polygons[[1]]@coords # Coordinates from the first
polygon
pas_file at polygons[[1]]@Polygons[[1]]@coords[,1] # All x from the first
polygon
pas_file at polygons[[1]]@Polygons[[1]]@coords[,2] # All y from the first
polygon
max(pas_file at polygons[[1]]@Polygons[[1]]@coords[,1])
min(pas_file at polygons[[1]]@Polygons[[1]]@coords[,1])
max(pas_file at polygons[[1]]@Polygons[[1]]@coords[,2])
min(pas_file at polygons[[1]]@Polygons[[1]]@coords[,2])
The shape file is a spatialPolygonsDataFrame so look at this link:
http://strimas.com/r/tidy-sf/
[[alternative HTML version deleted]]