Create a stamen or line map of the location of a list of LiPD objects

  map.type = "line",
  f = 0, = TRUE,
  projection = "mollweide",
  bound.circ = FALSE,
  global = FALSE,
  extend.range = 1,



longitude(s) range to map


latitude(s) range to map


"stamen" or "line"


buffer for the map range

TRUE or FALSE. Trim the size of the map to the points, for "line" map type


Map project. All options on: ?mapproject


Draw a boundary circle around a polar projection. TRUE or FALSE(default).


Should the scope of the map be global? TRUE or FALSE(default).


increase the span of the map by this much (lat/long degrees)


Arguments passed on to maps::map


character string naming a geographical database, a list of x, y, and names obtained from a previous call to map or a spatial object of class SpatialPolygons or SpatialLines. The string choices include a world map, three USA databases (usa, state, county), and more (type help(package='maps') to see the package index). If the requied database is in a different package that has not been attached, the string may be started with "packagename::". The location of the map databases may be overridden by setting the R_MAP_DATA_DIR environment variable.


character vector that names the polygons to draw. Each database is composed of a collection of polygons, and each polygon has a unique name. When a region is composed of more than one polygon, the individual polygons have the name of the region, followed by a colon and a qualifier, as in michigan:north and michigan:south. Each element of regions is matched against the polygon names in the database and, according to exact, a subset is selected for drawing. The regions may also be defined using (perl) regular expressions. This makes it possible to use 'negative' expressions like "Norway(?!:Svalbard)", which means Norway and all islands except Svalbard. All entries are case insensitive. The default selects all polygons in the database.


If TRUE, only exact matches with regions are selected for drawing. If FALSE, each element of regions is matched as a regular expression against the polygon names in the database and all matches are selected for drawing.


If FALSE, boundary segments are not drawn. A boundary segment is a line segment of the map that bounds only one of the polygons to be drawn. This argument is ignored if fill is TRUE.


If FALSE, interior segments are not drawn. An interior segment is a line segment of the map that bounds two of the polygons to be drawn. This argument is ignored if fill is TRUE.


numeric vector of parameters for use with the projection argument. This argument is optional only in the sense that certain projections do not require additional parameters. If a projection does require additional parameters, these must be given in the parameters argument.


a vector c(latitude, longitude, rotation) describing where the map should be centered and a clockwise rotation (in degrees) about this center.


logical flag that says whether to draw lines or fill areas. If FALSE, the lines bounding each region will be drawn (but only once, for interior lines). If TRUE, each region will be filled using colors from the col = argument, and bounding lines are drawn by default using par("fg"). To hide the bounding lines, use border=NA (see ...).


vector of colors. If fill is FALSE, the first color is used for plotting all lines, and any other colors are ignored. Otherwise, the colors are matched one-one with the polygons that get selected by the region argument (and are reused cyclically, if necessary). If fill = TRUE, the default boundary line colour is given by par("fg"). To change this, you can use the border argument (see '...'). A color of NA causes the corresponding region to be deleted from the list of polygons to be drawn. Polygon colors are assigned after polygons are deleted due to values of the xlim and ylim arguments.


logical flag that specifies whether plotting should be done. If plot is TRUE the return value of map will not be printed automatically .


logical flag that specifies whether to add to the current plot. If FALSE, a new plot is begun, and a new coordinate system is set up.


If TRUE, the return value will be a character vector of the names of the selected polygons. See the Value section below.


two element numeric vector giving a range of longitudes, expressed in degrees, to which drawing should be restricted. Longitude is measured in degrees east of Greenwich, so that, in particular, locations in the USA have negative longitude. If fill = TRUE, polygons selected by region must be entirely inside the xlim range. The default value of this argument spans the entire longitude range of the database.


two element numeric vector giving a range of latitudes, expressed in degrees, to which drawing should be restricted. Latitude is measured in degrees north of the equator, so that, in particular, locations in the USA have positive latitude. If fill = TRUE, polygons selected by region must be entirely inside the ylim range. The default value of this argument spans the entire latitude range of the database.


Boolean or a numeric vector. If TRUE, lines that cross too far across the map (due to a strange projection) are omitted. If wrap is a vector of length 2 or more, it is interpreted as the longitude range to be used for a global map, e.g. c(-180,180) or c(0,360). This wrapping even works when fill=TRUE and is performed before any projection (so the range must always be in degrees). However, the wrapping is performed after xlim, ylim are applied, so these options should probably never be combined. If there is a third component, this signifies the latitude at which Antarctica will be "closed". The default value is -89.9. Special values are NA (don't draw Antarctica at all) and 0 (draw the line at the latitude of the extremal points, not at a fixed lower latitude).


number that specifies the resolution with which to draw the map. Resolution 0 is the full resolution of the database. Otherwise, just before polylines are plotted they are thinned: roughly speaking, successive points on the polyline that are within resolution device pixels of one another are collapsed to a single point (see the Reference for further details). Thinning is not performed if plot = FALSE or when polygons are drawn (fill = TRUE or database is a list of polygons).


character string that controls drawing of the map. Aside from the default type = "l", the value type = "n" can be used to set up the coordinate system and projection for a map that will be added to in later calls.


background color.


margins, as in par. Defaults allow for map.axes().


scalar or vector of length 2 specifying the porportion of the plot to add to the defined or computed limits as borders.


A vector of column names to be used as region name if database is a SpatialPolygonsDataFrame. Ignored in all other cases.


Limit enforcement. Only taken into account if xlim and/or ylim are defined and (for "s" and "l") a projection is used. Possible values are "n" (none) "e" (exact),"s" (small),"l" (large). If lforce="e", map data is restricted exactly to the given limits prior to projection. This option affects the output value of the map, not only the plot window. If lforce="s", the four corners defined by xlim and ylim are projected and the plot window is restricted to the largest rectangle inside this region. "l" will result in a larger rectangle that includes the four corners. However, the parts that fall outside the original limits may not be complete (only polygons that partially fall inside the boundaries are included). This will also work with fill=TRUE. In this case the output value of the data is not changed, only the plot window is affected. These options are only useful for some projections.


ggmap base map

See also

Other mapping: mapLipd(), mapTs()


Nick McKay