get.locations | R Documentation |
Typical use case: you want the coordinates of all pixels with a value above a certain threshold
get.locations(im, condition)
im |
the image |
condition |
a function that takes scalars and returns logicals |
coordinates of all pixels such that condition(pixel) == TRUE
Simon Barthelme
im <- as.cimg(function(x,y) x+y,10,10)
get.locations(im,function(v) v < 4)
get.locations(im,function(v) v^2 + 3*v - 2 < 30)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.