Skip to content

Unexpected behavior of raster "mask" function

1 message · Robert J. Hijmans

#
Alex,
Thanks for the clear example. I had not considered that case.
I have added an argument 'updateNA' to the mask function (version
2.2-43) such that you can do:

masked_image <- mask(img, msk, updatevalue=2, updateNA=TRUE)

That is, if updateNA is TRUE, NA cells outside the mask are also updated.

Robert


On Fri, Jul 18, 2014 at 11:18 AM, Alex Zvoleff
<azvoleff at conservation.org> wrote: