.
From: R-help [r-help-boun...@r-project.org] on behalf of Ashraf Afana via
R-help [r-help@r-project.org]
Sent: 11 October 2017 13:55
To: r-help@r-project.org
Subject: [R] Iterate in a Spatial Polygon Dataframe in R?
Hi all,
I'm trying to iterate in a SpatialPolygonDataFrame thatcontains 110
Hi all,
I'm trying to iterate in a SpatialPolygonDataFrame thatcontains 110 features.
I tried to use the following code
iterate.spdf =function(x){ for (i in 1:nrow(x)){ p = x[i, ]} return(p)}
but with no success as it returns with aSpatialPolygonDataFrame that contains
onlyone feature. The
2 matches
Mail list logo