Is there a way to add a different polygon to a raster stack plot built using levelplot? For example, I plotted a raster stack comprised of 6 rasters. I would like to add a different polygon to each panel. However, when I add a layer, that layer is repeated across all six panels & my attempts to add addition polygons are result in those also being added to each panel.
#plot raster stack
levelplot(rStack, margin=F, xlab="", ylab="",
par.settings=list(strip.background=list(col="lightgray")),
names.attr=c("18000BP", "15000BP", "12000BP", "6000BP", "2050", "2090"),
scales = list(draw=F))
levelplot of raster stack without polygons
#plot raster stack & add polygons
levelplot(rStack, margin=F, xlab="", ylab="",
par.settings=list(strip.background=list(col="lightgray")),
names.attr=c("18000BP", "15000BP", "12000BP", "6000BP", "2050", "2090"),
scales = list(draw=F)) +
layer(sp.polygons(ice1)) + layer(sp.polygons(ice2))
levelplot with two polygons added, which are repeated across all panels