to_coord_polygon: Transform from coordinates system used in flow based...

View source: R/to_coord_polygon.R

to_coord_polygonR Documentation

Transform from coordinates system used in flow based cartogram to coordinates system used in the polygons

Description

Apply the mapping from the coordinates system used in flow based cartogram to the coordinates system used in the polygons (caracterised by the CRS)

Usage

to_coord_polygon(coord, carto)

Arguments

coord

a vector of length 2 or a two columns matrix containing xy coordinates to transform

carto

a cartogramR object

Value

a vector of length 2 or a two columns matrix containing xy coordinates in the coordinate systems of polygons used to build the cartogram

Examples

 
  data(usa)
  carto <- cartogramR(usa, "electors64")
  to_coord_polygon(c(256,256), carto)
 



cartogramR documentation built on Sept. 11, 2024, 5:48 p.m.