| as.s2im.function | R Documentation | 
Convert Function on the Sphere to an Image/Raster on the Sphere
as.s2im.function(f, region = NULL, ..., level = NULL)
| f | function of degrees longitude and latitude in that order. | 
| region | Object of class  | 
| ... | Ignored. | 
| level | Integer level of the pixels between 0 (each pixel is huge – millions of square kilometres on Earth) and 30 (each pixel is tiny – approximately a square cm on Earth). | 
Object of class s2im.
poly <- s2polygon(cbind(lon = c(-20,-10,10,20,10,-10), lat = c(0, -10, -10, 0, 10, 10)))
f <- function(lon, lat){ sin(lon) }
im <- as.s2im.function(f, poly, level = 6)
plot(im)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.