world.legacy(), which were deprecated for some years, have been removed from the package. The old database is now available from the companion package 'mapdata' (as of version 2.3.0) where it is called "worldLores".
Minor code changes (removal of deprecated macro, small bugfixes)
Some corrections to country, island and city names.
world.legacy() have been deprecated. The old database is now available from the companion package 'mapdata' (as of version 2.3.0) where it is called "worldLores".
Makefile has been fixed for possible whitespace in $R_HOME and for pre-existing $AWKPATH.
Various small fixes in data sets.
New map wrapping code should eliminate border artefacts on world maps, even with
fill=TRUE. It can be called via
map(..., wrap=c(0,360),...), i.e. by giving
wrap a vector in stead of a boolean value. The wrapping code is also directly available as
map.wrap.poly(data, xlim, poly=FALSE, antarctica=TRUE)
map() has a new argument
lforce (force limits). Possible values are
"n" (no, default),
"e" (exact limits),
"s" (small enclosed rectangle) and
"l" (large, enclosing rectangle). Forcing the limits will limit your map more forcibly to the given limits.
"s","l" only impact the plotting window, but with
"e" the data itself is clipped exactly to the borders.
The clipping code is also directly available as
map.clip.poly(data, xlim=NULL, ylim=NULL, poly=FALSE).
All functions should now work if the package is not attached. So you can do
maps::map() and even
A long standing bug in map.where() was fixed. It probably only showed up with the "county" database (and only for about 20 counties in Missouri). The C code has also been optimised.
map() could have problems if
regions was a factor rather than a character vector.
Minor correction to
Fixed some duplicated region names in
The return value of
SpatialPolygons2map() now has class
county.state: changed from factors to character vectors.
The C functions are now registered.
maptype() always returned
"spherical" for external databases. Now it is possible to add a
maptype manually, e.g.
mymap$maptype <- "planar".
When using projections,
map() now checks for the availability of
mapproj and gives a nicer message if it isn't available.
perl style regex caused problems for very long lists of regions. Fixed by setting perl=FALSE if the list of regions contains more than 1000 entries or the resulting regex is more than 30000 characters long.
A few minor corrections to country and city names.
Removed start-up message.
'world' database changed to version without lakes punched out at the borders. The previous version still had various issues, so this is much cleaner. Now 'interior=FALSE' actually works on the whole world map.
Major lakes are now available from a separate database 'lakes'.
Basic support for 'SpatialPolygons' and 'SpatialLines' class objects as map database. Internally,
maps() calls new functions
SpatialLines2map() which transform to the simple 'maps' format, but only the polygon names and coordinates themselves. All other information (holes, plotting order etc.) is ignored.
'world2' (the pacific centered map) now has clean cut polygons at the boundaries, so there are no more artefacts when e.g.
map() now (silently) ignores thinning (
resolution>0) when drawing polygons in stead of polylines. This was already the case for list-based maps, but not for
fill=TRUE. The assymetric thinning caused artefacts. Plotting may be a bit slower now, noticably so for 'worldHires'. But usually you don't want to plot a complete world map at such a high resolution anyway.
wrap=TRUE is no longer ignored when
plot=FALSE. Also, wrapping is now called before thinning, which should give slightly better results.
removed $(AWK) macro from Makefile and added simple configuration script.
maps:::subgroup adapted to be much faster. Very noticable when selecting a large subset of polygons from a polygon database (not file-based).
map.wrap() for wrapping around the globe. The new version fixes some bugs, is a bit faster and also adds an option for maps not centered around 0.
World database rebuilt using mapMaker. Some corrections to polylines.
Added the lakes on country boundaries as new polygons. That way, the dissappear when plotting with map(..., fill=TRUE) and map(..., interior=FALSE).
Minor changes to man pages.
Fix match.map() for world map
Add some more island names to the world database
Updated a few web references in man pages.
New 'world' database, taken from the public domain "Natural Earth" project. Many new countries have appeared since 1990. E.g.
map(region="USSR") will no longer work.
The old map is still available as 'legacy_world'. It is also possible (during a transition period) to switch completely to the old database by giving the command
world.legacy(TRUE) or even by setting the environment variable 'R_MAP_DATA_LEGACY=TRUE' prior to loading the package.
iso3166 containing ISO-3166 country codes.
iso.alpha() that use this table for converting country names to ISO codes or back. Also expansion by sovereignty. Could be used e.g. for country labels.
SMALL CHANGES & FIXES
Internally now uses perl-style regular expressions. Useful for e.g. 'negative' regular expressions:
"Norway(?!:Svalbard)" means Norway and all islands except Svalbard.
map(reg="(?!Belgium)", fill=TRUE, xlim=c(-10,20), ylim=c(40,60))
map.text(...,exact=TRUE) now behaves as documented. To get the old (non-documented) behaviour (plot map with exact=FALSE, write text for exact=TRUE) you could now use 2 commands:
match.map had a potential bug with locale-dependent behaviour of