-
Notifications
You must be signed in to change notification settings - Fork 110
map
Adds all images from an ee.ImageCollection
to the Map. Argument options
:
-
visParams
: visualization parameters (for all images) -
active
:true
make layers to be active when added. Defaults tofalse
for speed reasons -
namePattern
: a name pattern. See: https://github.com/fitoprincipe/geetools-code-editor/wiki/image#makenameimage-pattern-properties-datepattern -
properties
: a list of properties used innamePattern
-
datePattern
: the pattern for dates
https://code.earthengine.google.com/dc0504810a77c87d4be2acd232ed36f9
Remove a layer from a map by its name. If argument map
is not passed, it will use the default Map
. If the name is duplicated it will be removed in all instances. Returns a list with the indexes of the replaced layers.
Remove a layer (ui.Map.Layer
) from a map. If argument map
is not passed, it will use the default Map
. Returns a list with the indexes of the replaced layers.
Remove an Earth Engine object (ee.Image
, ee.Geometry
, etc) from the map. If argument map
is not passed, it will use the default Map
. Returns a list with the indexes of the replaced layers.
Replace a layer (ui.Map.Layer
) for newlayer
in the map. If argument map
is not passed, it will use the default Map
. Returns a list with the indexes of the replaced layers.
Get a layer by its name. Return the layer (not the eeObject
)
var image = ee.Image(0) // test image
Map.addLayer(image, {min:0, max:1}, 'layer_name')
var layer = tools.map.getLayer('layer_name')
var layer_object = layer.getEeObject() // the image
var layer_name = layer.getName()
var layer_vis = layer.getVisParams()
// etc..
https://code.earthengine.google.com/024ee27e25be6439e3f0b81d674019f4
- @author: Rodrigo E. Principe
- email: fitoprincipe82 at gmail
- Licence: MIT