Learn R Programming

tmap (version 0.7)

read_shape: Read shape file

Description

Read an ESRI shape file. Optionally, set the current projection if it is missing.

Usage

read_shape(file, current.projection = NULL)

Arguments

file
a shape file name (including directory).
current.projection
the current projection of the shape object, if it is missing in the shape file. It should be either a PROJ.4 character string (see http://trac.osgeo.org/proj/), of one of the following shortcuts: [object Object],[object Object],[o

Value

  • shape object

Details

This function is a convenient wrapper of readOGR of the package rgdal. It is possible to set the current projection, if it is undefined in the shape file. If a reprojection is required, use set_projection.