The visualization parameters. For Images and ImageCollection, see ee.data.getMapId for valid parameters. For Features and FeatureCollections, the only supported key is "color", as a CSS 3.0 color string or a hex string in "RRGGBB" format. Ignored when eeObject is a map ID.
name
String, optional
The name of the layer. Defaults to "Layer N".
shown
Boolean, optional
A flag indicating whether the layer should be on by default.
opacity
Number, optional
The layer's opacity represented as a number between 0 and 1. Defaults to 1.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2023-10-06 UTC."],[[["`Map.addLayer()` overlays Earth Engine objects like images and features onto the map as a new layer."],["Visualization parameters can be customized using the `visParams` argument to control how the layer is displayed."],["This function accepts Earth Engine objects (like Image, FeatureCollection, Geometry), visualization parameters, layer name, visibility, and opacity as arguments."],["The function returns the added map layer as a `ui.Map.Layer` object, which can be further manipulated."],["Pre-styled images or those with inherent visualization can be added by setting `visParams` to null."]]],["The `Map.addLayer` function adds an Earth Engine object to a map as a layer, returning the new `ui.Map.Layer`. It accepts an `eeObject` (Collection, Feature, Image, or RawMapId), optional `visParams` for visualization, `name` for the layer's label, `shown` (boolean) to set default visibility, and `opacity` (0-1). Visualization parameters vary by object type; `color` is the only supported parameter for Features, while Images support `bands`, `min`, `max`, and `palette`. ImageCollections are mosaicked, and the last images take precedence.\n"]]