[R-sig-Geo] computing square kilometers in shape file polygons

Robert J. Hijmans r.hijmans at gmail.com
Sat Sep 4 00:55:25 CEST 2010


Joe,

The "areaPolygon" function in the "geosphere" package can do this.

Robert

On Fri, Sep 3, 2010 at 3:30 PM,  <brwin338 at aol.com> wrote:
>
> Good Afternoon
> Does any one know of a package/function that could be used to compute the square kilometers for polygons in a long-lat projected shapefile?
> I can access the values in the "area" slots in the object resulting from using maptool's  "readShapePoly" command.  I have approximated the km^2 from these values by using one of the polygons's (such as a given state's) known area in km^2 and rescaling the polygon's "area" relative to the state's known area.  I then applied this "scaling factor" to the other polygons in my shapefile object to approximate the other polygons' are in km^2.
>
> However, if I understand things correctly, my approximate "area to km^2" scaling  will become increasing distorted as I move north or south relative to my original "normalizing" state.  Is there a function that can compensate for changes in latitude when computing the polygon areas associated with long-lat polygons?  I hope this question is somewhat coherent
> Thanks
> Joe
>
>
>
>
>        [[alternative HTML version deleted]]
>
> _______________________________________________
> R-sig-Geo mailing list
> R-sig-Geo at stat.math.ethz.ch
> https://stat.ethz.ch/mailman/listinfo/r-sig-geo
>



More information about the R-sig-Geo mailing list