# NOT RUN {
library(rgee)
ee_reattach() # reattach ee as a reserved word
ee_Initialize()
# Case: Geometry*
geom <- ee$Geometry$Point(list(-73.53522, -15.75453))
m1 <- ee_map(
eeobject = geom,
vizparams = list(pointRadius = 10, color = "FF0000"),
objname = "Geometry-Arequipa"
)
m1
# Case: Feature
eeobject_fc <- ee$FeatureCollection("users/csaybar/DLdemos/train_set")$
first()
m2 <- ee_map(eeobject = ee$Feature(eeobject_fc),
objname = "Feature-Arequipa")
m2 + m1
# Case: FeatureCollection
eeobject_fc <- ee$FeatureCollection("users/csaybar/DLdemos/train_set")
m3 <- ee_map(eeobject = eeobject_fc, objname = "FeatureCollection")
m3 + m2 + m1
# Case: Image
image <- ee$Image("LANDSAT/LC08/C01/T1/LC08_044034_20140318")
m4 <- ee_map(
eeobject = image,
vizparams = list(
bands = c("B4", "B3", "B2"),
max = 10000
),
objname = "SF",
zoom_start = "8"
)
m4
# Case: ImageCollection
collection <- ee$ImageCollection("LANDSAT/LC08/C01/T1_TOA")$
filter(ee$Filter()$eq("WRS_PATH", 44))$
filter(ee$Filter()$eq("WRS_ROW", 34))$
filterDate("2014-01-01", "2015-01-01")$
sort("CLOUD_COVER")
m5 <- ee_map(
eeobject = collection,
vizparams = list(bands = c("B4", "B3", "B2"), max = 1),
objname = c("Scene_2019", "Scene_2016", "Scene_2011"),
max_nimage = 3,
zoom_start = 10
)
m5
# }
Run the code above in your browser using DataLab