| antipolygon | R Documentation | 
This routine does the inverse of 'polygon': it colours everything outside a given polygnon. This may be useful for e.g. blanking out a plot outside certain borders. This routine is quite simple and may not work under all circumstances.
antipolygon(data,xylim=DomainExtent(.Last.domain()), bg='white')
data | 
 A polygon (x and y columns).  | 
bg | 
 Colour to use.  | 
xylim | 
 Boundaries for the 'antipolygon'. Usually the boundaries of the presentt plot.  | 
antipolygon() works by adding the 4 corner points to the polygon, thus 'inverting' it.
limage,vecplot
 ## Not run: 
mask <- project(map("world","Belgium",fill=0,plot=FALSE))
xylim <- DomainExtent(datafield)
antipolygon(mask,xylim=xylim)
## End(Not run) 
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.