Title: | 'tidyverse' Methods for 'Earth Engine' |
---|---|
Description: | Provides 'tidyverse' methods for wrangling and analyzing 'Earth Engine' <https://earthengine.google.com/> data. These methods help the user with filtering, joining and summarising 'Earth Engine' image collections. |
Authors: | Zack Arno [aut, cre, cph], Josh Erickson [aut, cph] |
Maintainer: | Zack Arno <[email protected]> |
License: | MIT + file LICENSE |
Version: | 0.1.0 |
Built: | 2024-11-12 05:12:38 UTC |
Source: | https://github.com/r-tidy-remote-sensing/tidyrgee |
append date to band name
add_date_to_bandname(x)
add_date_to_bandname(x)
x |
ee$ImageCollection or ee$Image |
a date to band name in x.
as_ee tidyee to ee$ImageCollection or ee$Image
as_ee(x)
as_ee(x)
x |
tidyee |
ee$ImageCollection or ee$Image
## Not run: library(rgee) librar(tidyee) modis_ic <- ee$ImageCollection("MODIS/006/MOD13Q1") # create tidyee class modis_ic_tidy <- as_tidyee(modis_ic) # convert back to origina ee$ImageCollection class modis_ic_tidy |> as_ee() ## End(Not run)
## Not run: library(rgee) librar(tidyee) modis_ic <- ee$ImageCollection("MODIS/006/MOD13Q1") # create tidyee class modis_ic_tidy <- as_tidyee(modis_ic) # convert back to origina ee$ImageCollection class modis_ic_tidy |> as_ee() ## End(Not run)
The function returns a list containing the original object (Image/ImageCollection)as well as a "virtual data.frame (vrt)" which is a data.frame holding key properties of the ee$Image/ee$ImageCollection. The returned list has been assigned a new class "tidyee".
as_tidyee(x, time_end = FALSE)
as_tidyee(x, time_end = FALSE)
x |
ee$Image or ee$ImageCollection |
time_end |
|
tidyee class object which contains a list with two components ("x","vrt")
## Not run: library(tidyrgee) library(rgee) ee_Initialize() modis_ic <- ee$ImageCollection("MODIS/006/MOD13Q1") modis_ic_tidy <- as_tidyee(modis_ic) ## End(Not run)
## Not run: library(tidyrgee) library(rgee) ee_Initialize() modis_ic <- ee$ImageCollection("MODIS/006/MOD13Q1") modis_ic_tidy <- as_tidyee(modis_ic) ## End(Not run)
Data frame of responses with anonymized coordinates
bgd_msna
bgd_msna
A data frame with 1374 rows and 15 variables:
unique identifier
informed consent
date of survey
date of end of survey
question about electricity grid
question about solar light
repeat group calculation on # hh members with illness in past x days
select multiple response - did HH collect firewood for cooking fuel
income source question - ariculture
question on agricultural land
employment source - ag
employment source - non-ag
employment source - fishing
longitude - jittered/anonymized
latitude - jittered/anonymized
...
data frame
bind ImageCollections
bind_ics(x)
bind_ics(x)
x |
list of tidyee objects |
tidyee object containing single image collection and vrt
## Not run: library(tidyrgee) library(rgee) ee_Initialize() modis_ic <- ee$ImageCollection("MODIS/006/MOD13Q1") modis_ic_tidy <- as_tidyee(modis_ic) modis_tidy_list <- modis_tidy |> group_split(month) modis_tidy_list |> bind_ics() ## End(Not run)
## Not run: library(tidyrgee) library(rgee) ee_Initialize() modis_ic <- ee$ImageCollection("MODIS/006/MOD13Q1") modis_ic_tidy <- as_tidyee(modis_ic) modis_tidy_list <- modis_tidy |> group_split(month) modis_tidy_list |> bind_ics() ## End(Not run)
allows clipping of tidyee,ee$Imagecollection, or ee$Image classes. Also allows objects to be clipped to sf object in addition to ee$FeatureCollections/ee$Feature
clip(x, y, return_tidyee = TRUE)
clip(x, y, return_tidyee = TRUE)
x |
object to be clipped (tidyee, ee$ImageCollection, ee$Image) |
y |
geometry object to clip to (sf, ee$Feature,ee$FeatureCollections) |
return_tidyee |
|
x as tidyee or ee$Image/ee$ImageCollection depending on return_tidyee
argument.
## Not run: library(tidyrgee) library(tidyverse) library(rgee) rgee::ee_Initialize() # create geometry and convert to sf coord_tibble <- tibble::tribble( ~X, ~Y, 92.2303683692011, 20.9126490153521, 92.2311567217866, 20.9127410439304, 92.2287527311594, 20.9124072954926, 92.2289221219251, 20.9197352745068, 92.238724724534, 20.9081803233546 ) sf_ob <- sf::st_as_sf(coord_tibble, coords=c("X","Y"),crs=4326) roi <- ee$Geometry$Polygon(list( c(-114.275, 45.891), c(-108.275, 45.868), c(-108.240, 48.868), c(-114.240, 48.891) )) # load landsat ls = ee$ImageCollection("LANDSAT/LC08/C01/T1_SR") # create tidyee class ls_tidy <- as_tidyee(ls) # filter_bounds on sf object # return tidyee object ls_tidy |> filter_bounds(y = roi,return_tidyee = FALSE) |> clip(roi,return_tidyee = FALSE) # pretty instant with return_tidyee=FALSE ls_clipped_roi_ic <- ls_tidy |> filter_bounds(y = roi,return_tidyee = FALSE) |> clip(roi,return_tidyee = FALSE) # takes more time with return_tidyee=T, but you get the vrt ls_clipped__roi_tidyee <- ls_tidy |> filter_bounds(y = roi,return_tidyee = FALSE) |> clip(roi,return_tidyee = TRUE) # demonstrating on sf object ls_clipped_sf_ob_ic <- ls_tidy |> filter_bounds(y = sf_ob,return_tidyee = FALSE) |> clip(roi,return_tidyee = FALSE) ls_clipped_sf_ob_tidyee <- ls_tidy |> filter_bounds(y = roi,return_tidyee = FALSE) |> clip(roi,return_tidyee = TRUE) ## End(Not run)
## Not run: library(tidyrgee) library(tidyverse) library(rgee) rgee::ee_Initialize() # create geometry and convert to sf coord_tibble <- tibble::tribble( ~X, ~Y, 92.2303683692011, 20.9126490153521, 92.2311567217866, 20.9127410439304, 92.2287527311594, 20.9124072954926, 92.2289221219251, 20.9197352745068, 92.238724724534, 20.9081803233546 ) sf_ob <- sf::st_as_sf(coord_tibble, coords=c("X","Y"),crs=4326) roi <- ee$Geometry$Polygon(list( c(-114.275, 45.891), c(-108.275, 45.868), c(-108.240, 48.868), c(-114.240, 48.891) )) # load landsat ls = ee$ImageCollection("LANDSAT/LC08/C01/T1_SR") # create tidyee class ls_tidy <- as_tidyee(ls) # filter_bounds on sf object # return tidyee object ls_tidy |> filter_bounds(y = roi,return_tidyee = FALSE) |> clip(roi,return_tidyee = FALSE) # pretty instant with return_tidyee=FALSE ls_clipped_roi_ic <- ls_tidy |> filter_bounds(y = roi,return_tidyee = FALSE) |> clip(roi,return_tidyee = FALSE) # takes more time with return_tidyee=T, but you get the vrt ls_clipped__roi_tidyee <- ls_tidy |> filter_bounds(y = roi,return_tidyee = FALSE) |> clip(roi,return_tidyee = TRUE) # demonstrating on sf object ls_clipped_sf_ob_ic <- ls_tidy |> filter_bounds(y = sf_ob,return_tidyee = FALSE) |> clip(roi,return_tidyee = FALSE) ls_clipped_sf_ob_tidyee <- ls_tidy |> filter_bounds(y = roi,return_tidyee = FALSE) |> clip(roi,return_tidyee = TRUE) ## End(Not run)
helper function to assign new tidyee when running as_tidyee
create_tidyee(x, vrt)
create_tidyee(x, vrt)
x |
ee$ImageCollection |
vrt |
virtual table |
tidyee class list object
ee_composite
ee_composite(x, ...) ## S3 method for class 'tidyee' ee_composite(x, stat, ...)
ee_composite(x, ...) ## S3 method for class 'tidyee' ee_composite(x, stat, ...)
x |
tidyee object containing |
... |
other arguments |
stat |
A |
tidyee class containing ee$Image
where all images within ee$ImageCollection
have been aggregated based on pixel-level stats
ee_extract_tidy
ee_extract_tidy( x, y, stat = "mean", scale, via = "getInfo", container = "rgee_backup", sf = TRUE, lazy = FALSE, quiet = FALSE, ... )
ee_extract_tidy( x, y, stat = "mean", scale, via = "getInfo", container = "rgee_backup", sf = TRUE, lazy = FALSE, quiet = FALSE, ... )
x |
tidyee, ee$Image, or ee$ImageCollection |
y |
sf or ee$feature or ee$FeatureCollection |
stat |
zonal stat ("mean", "median" , "min","max" etc) |
scale |
A nominal scale in meters of the Image projection to work in. By default 1000. |
via |
Character. Method to export the image. Three method are implemented: "getInfo", "drive", "gcs". |
container |
Character. Name of the folder ('drive') or bucket ('gcs') to be exported into (ignore if via is not defined as "drive" or "gcs"). |
sf |
Logical. Should return an sf object? |
lazy |
Logical. If TRUE, a future::sequential object is created to evaluate the task in the future. Ignore if via is set as "getInfo". See details. |
quiet |
Logical. Suppress info message. |
... |
additional parameters |
data.frame in long format with point estimates for each time-step and y feature based on statistic provided
ee_extract
for information about ee_extract on ee$ImageCollections and ee$Images
## Not run: library(rgee) library(tidyrgee) ee_Initizialize() modis_ic <- ee$ImageCollection("MODIS/006/MOD13Q1") point_sample_buffered <- tidyrgee::bgd_msna |> sample_n(3) |> sf::st_as_sf(coords=c("_gps_reading_longitude", "_gps_reading_latitude"), crs=4326) |> sf::st_transform(crs=32646) |> sf::st_buffer(dist = 500) |> dplyr::select(`_uuid`) modis_ic_tidy <- as_tidyee(modis_ic) modis_monthly_baseline_mean <- modis_ic_tidy |> select("NDVI") |> filter(year %in% 2000:2015) |> group_by(month) |> summarise(stat="mean") ndvi_monthly_mean_at_pt<- modis_monthly_baseline_mean |> ee_extract(y = point_sample_buffered, fun="mean", scale = 500) ## End(Not run)
## Not run: library(rgee) library(tidyrgee) ee_Initizialize() modis_ic <- ee$ImageCollection("MODIS/006/MOD13Q1") point_sample_buffered <- tidyrgee::bgd_msna |> sample_n(3) |> sf::st_as_sf(coords=c("_gps_reading_longitude", "_gps_reading_latitude"), crs=4326) |> sf::st_transform(crs=32646) |> sf::st_buffer(dist = 500) |> dplyr::select(`_uuid`) modis_ic_tidy <- as_tidyee(modis_ic) modis_monthly_baseline_mean <- modis_ic_tidy |> select("NDVI") |> filter(year %in% 2000:2015) |> group_by(month) |> summarise(stat="mean") ndvi_monthly_mean_at_pt<- modis_monthly_baseline_mean |> ee_extract(y = point_sample_buffered, fun="mean", scale = 500) ## End(Not run)
Pixel-level composite by month
ee_month_composite(x, ...) ## S3 method for class 'ee.imagecollection.ImageCollection' ee_month_composite(x, stat, months, ...) ## S3 method for class 'tidyee' ee_month_composite(x, stat, ...)
ee_month_composite(x, ...) ## S3 method for class 'ee.imagecollection.ImageCollection' ee_month_composite(x, stat, months, ...) ## S3 method for class 'tidyee' ee_month_composite(x, stat, ...)
x |
An earth engine ImageCollection or tidyee class. |
... |
extra args to pass on |
stat |
A |
months |
A vector of months, e.g. c(1, 12). |
tidyee class containing ee$Image
or ee$ImageCollection
with pixels aggregated by month
ee_month_filter
ee_month_filter(imageCol, month, ...)
ee_month_filter(imageCol, month, ...)
imageCol |
ee$ImageCollection |
month |
|
... |
other arguments |
ee$ImageCollection or ee$Image filtered by month
Pixel level composite by year
ee_year_composite(x, ...) ## S3 method for class 'ee.imagecollection.ImageCollection' ee_year_composite(x, stat, year, ...) ## S3 method for class 'tidyee' ee_year_composite(x, stat, ...)
ee_year_composite(x, ...) ## S3 method for class 'ee.imagecollection.ImageCollection' ee_year_composite(x, stat, year, ...) ## S3 method for class 'tidyee' ee_year_composite(x, stat, ...)
x |
An earth engine ImageCollection or tidyee class. |
... |
other arguments |
stat |
A |
year |
|
tidyee class containing ee$Image
or ee$ImageCollection
with pixels aggregated by year
ee_year_filter
ee_year_filter(imageCol, year, ...)
ee_year_filter(imageCol, year, ...)
imageCol |
ee$ImageCollection |
year |
|
... |
other arguments |
ee$ImageCollection or ee$Image filtered by year
Pixel-level composite by year and month
ee_year_month_composite(x, ...) ## S3 method for class 'ee.imagecollection.ImageCollection' ee_year_month_composite(x, stat, startDate, endDate, months, ...) ## S3 method for class 'tidyee' ee_year_month_composite(x, stat, ...)
ee_year_month_composite(x, ...) ## S3 method for class 'ee.imagecollection.ImageCollection' ee_year_month_composite(x, stat, startDate, endDate, months, ...) ## S3 method for class 'tidyee' ee_year_month_composite(x, stat, ...)
x |
An earth engine ImageCollection or tidyee class. |
... |
args to pass on. |
stat |
A |
startDate |
|
endDate |
|
months |
|
tidyee class containing ee$Image
or ee$ImageCollection
with pixels aggregated by year and month
ee_year_month_filter
ee_year_month_filter(imageCol, year, month, ...)
ee_year_month_filter(imageCol, year, month, ...)
imageCol |
ee$ImageCollection |
year |
|
month |
|
... |
other arguments |
ee$ImageCollection or ee$Image filtered by year & month
filter ee$ImageCollections or tidyee objects that contain imageCollections
.data |
ImageCollection or tidyee class object |
... |
other arguments |
filtered image or imageCollection form filtered imageCollection
filter
for information about filter on normal data tables.
## Not run: library(rgee) library(tidyrgee) ee_Initialize() l8 = ee$ImageCollection('LANDSAT/LC08/C01/T1_SR') l8 |> filter(date>"2016-01-01",date<"2016-03-04") # example with tidyee ckass modis_ic <- ee$ImageCollection("MODIS/006/MOD13Q1") modis_ic_tidy <- as_tidyee(modis_ic) # filter by month modis_march_april <- modis_ic_tidy |> filter(month %in% c(3,4)) ## End(Not run)
## Not run: library(rgee) library(tidyrgee) ee_Initialize() l8 = ee$ImageCollection('LANDSAT/LC08/C01/T1_SR') l8 |> filter(date>"2016-01-01",date<"2016-03-04") # example with tidyee ckass modis_ic <- ee$ImageCollection("MODIS/006/MOD13Q1") modis_ic_tidy <- as_tidyee(modis_ic) # filter by month modis_march_april <- modis_ic_tidy |> filter(month %in% c(3,4)) ## End(Not run)
filter_bounds a wrapper for rgee::ee$ImageCollection$filterBounds
filter_bounds(x, y, use_tidyee_index = FALSE, return_tidyee = TRUE)
filter_bounds(x, y, use_tidyee_index = FALSE, return_tidyee = TRUE)
x |
tidyee object containing ee$ImageCollection or ee$ImageCollection |
y |
feature to filter bounds by (sf, ee$FeatureCollection, ee$Feature, ee$Geometry) |
use_tidyee_index |
filter on tidyee_index (default = F) or system_index (by default) |
return_tidyee |
|
tidyee class or ee$ImageCollection class object with scenes filtered to bounding box of y geometry
## Not run: library(tidyrgee) library(tidyverse) library(rgee) rgee::ee_Initialize() # create geometry and convert to sf coord_tibble <- tibble::tribble( ~X, ~Y, 92.2303683692011, 20.9126490153521, 92.2311567217866, 20.9127410439304, 92.2287527311594, 20.9124072954926, 92.2289221219251, 20.9197352745068, 92.238724724534, 20.9081803233546 ) sf_ob <- sf::st_as_sf(coord_tibble, coords=c("X","Y"),crs=4326) # load landsat ls = ee$ImageCollection("LANDSAT/LC08/C01/T1_SR") #create tidyee class ls_tidy <- as_tidyee(ls) # filter_bounds on sf object # return tidyee object ls_tidy |> filter_bounds(sf_ob) # return ee$ImageCollection ls_tidy |> filter_bounds(sf_ob,return_tidyee = FALSE) # filter_bounds on ee$Geometry object # return tidyee object ee_geom_ob <- sf_ob |> rgee::ee_as_sf() ls_tidy |> filter_bounds(ee_geom_ob) ## End(Not run)
## Not run: library(tidyrgee) library(tidyverse) library(rgee) rgee::ee_Initialize() # create geometry and convert to sf coord_tibble <- tibble::tribble( ~X, ~Y, 92.2303683692011, 20.9126490153521, 92.2311567217866, 20.9127410439304, 92.2287527311594, 20.9124072954926, 92.2289221219251, 20.9197352745068, 92.238724724534, 20.9081803233546 ) sf_ob <- sf::st_as_sf(coord_tibble, coords=c("X","Y"),crs=4326) # load landsat ls = ee$ImageCollection("LANDSAT/LC08/C01/T1_SR") #create tidyee class ls_tidy <- as_tidyee(ls) # filter_bounds on sf object # return tidyee object ls_tidy |> filter_bounds(sf_ob) # return ee$ImageCollection ls_tidy |> filter_bounds(sf_ob,return_tidyee = FALSE) # filter_bounds on ee$Geometry object # return tidyee object ee_geom_ob <- sf_ob |> rgee::ee_as_sf() ls_tidy |> filter_bounds(ee_geom_ob) ## End(Not run)
Group an imageCollection or tidyee object with Imagecollections by a parameter
.data |
ee$ImageCollection or tidyee object |
... |
group_by variables |
.add |
When This argument was previously called |
.drop |
Drop groups formed by factor levels that don't appear in the
data? The default is |
ee$ImageCollection with grouped_vars attribute
group_by
for information about group_by on normal data tables.
## Not run: library(tidyrgee) ee_Initialize() modis_ic <- ee$ImageCollection("MODIS/006/MOD13Q1") modis_ic |> filter(date>="2016-01-01",date<="2019-12-31") |> group_by(year) ## End(Not run)
## Not run: library(tidyrgee) ee_Initialize() modis_ic <- ee$ImageCollection("MODIS/006/MOD13Q1") modis_ic |> filter(date>="2016-01-01",date<="2019-12-31") |> group_by(year) ## End(Not run)
filter ee$ImageCollections or tidyee objects that contain imageCollections
.tbl |
ImageCollection or tidyee class object |
... |
other arguments |
return_tidyee |
|
filtered image or imageCollection form filtered imageCollection
group_split
for information about filter on normal data tables.
## Not run: library(rgee) library(tidyrgee) ee_Initialize() l8 = ee$ImageCollection('LANDSAT/LC08/C01/T1_SR') l8 |> filter(date>"2016-01-01",date<"2016-03-04") # example with tidyee ckass modis_ic <- ee$ImageCollection("MODIS/006/MOD13Q1") modis_ic_tidy <- as_tidyee(modis_ic) # filter by month modis_march_april <- modis_ic_tidy |> filter(month %in% c(3,4)) ## End(Not run)
## Not run: library(rgee) library(tidyrgee) ee_Initialize() l8 = ee$ImageCollection('LANDSAT/LC08/C01/T1_SR') l8 |> filter(date>"2016-01-01",date<"2016-03-04") # example with tidyee ckass modis_ic <- ee$ImageCollection("MODIS/006/MOD13Q1") modis_ic_tidy <- as_tidyee(modis_ic) # filter by month modis_march_april <- modis_ic_tidy |> filter(month %in% c(3,4)) ## End(Not run)
inner_join bands from different image/ImageCollections based on shared property
x , y
|
A pair of tidyee objects containing ee$ImageCollections |
by |
A character vector of variables to join by. |
An object of the same type as x
. The output has the following properties:
Same number of images as x
Total number of bands equal the number of bands in x
plus the number of bands in y
inner_join
for information about inner_join on normal data tables.
mutate columns into tidyee vrt which can later be used to modify tidyee ImageCollection
.data |
tidyee class object (list of ee_ob, vrt) |
... |
mutate arguments |
return tidyee class object with vrt data.frame mutated.
mutate
for information about mutate on normal data tables.
## Not run: library(tidyrgee) library(rgee) ee_Initialize() modis_ic <- ee$ImageCollection("MODIS/006/MOD13Q1") modis_ic_tidy <- as_tidyee(modis_ic) ## End(Not run)
## Not run: library(tidyrgee) library(rgee) ee_Initialize() modis_ic <- ee$ImageCollection("MODIS/006/MOD13Q1") modis_ic_tidy <- as_tidyee(modis_ic) ## End(Not run)
print tidyee
## S3 method for class 'tidyee' print(x, ...)
## S3 method for class 'tidyee' print(x, ...)
x |
tidyee object |
... |
additional arguments |
printed tidyee object
Select bands from ee$Image or ee$ImageCollection
.data |
tidyee class object containing ee$ImageCollection or ee$Image |
... |
one or more quoted or unquoted expressions separated by commas. |
tidyee class object with specified (...) bands selected
select
for information about select on normal data tables.
## Not run: library(tidyrgee) ee_Initialize() modis_ic <- ee$ImageCollection("MODIS/006/MOD13Q1") modis_ic_tidy <- as_tidyee(modis_ic) # select NDVI band modis_ndvi <- modis_ic_tidy |> select("NDVI") # select NDVI band, but change band to new name modis_ndvi_renamed <- modis_ic_tidy |> select(ndvi_new= "NDVI") ## End(Not run)
## Not run: library(tidyrgee) ee_Initialize() modis_ic <- ee$ImageCollection("MODIS/006/MOD13Q1") modis_ic_tidy <- as_tidyee(modis_ic) # select NDVI band modis_ndvi <- modis_ic_tidy |> select("NDVI") # select NDVI band, but change band to new name modis_ndvi_renamed <- modis_ic_tidy |> select(ndvi_new= "NDVI") ## End(Not run)
set_idx
set_idx(x, idx_name = "tidyee_index")
set_idx(x, idx_name = "tidyee_index")
x |
tidyee or |
idx_name |
name for index to create (default = "tidyee_index") |
tidyee or ee$ImageCollection
class object with new index containing sequential 0-based indexing
## Not run: library(rgee) library(tidyrgee) ee_Initialize() modis_link <- "MODIS/006/MOD13Q1" modisIC <- ee$ImageCollection(modis_link) modis_ndvi_tidy <- as_tidyee(modisIC) |> select("NDVI") modis_ndvi_tidy |> ## End(Not run)
## Not run: library(rgee) library(tidyrgee) ee_Initialize() modis_link <- "MODIS/006/MOD13Q1" modisIC <- ee$ImageCollection(modis_link) modis_ndvi_tidy <- as_tidyee(modisIC) |> select("NDVI") modis_ndvi_tidy |> ## End(Not run)
slice ee$ImageCollections or tidyee objects that contain imageCollections
.data |
ImageCollection or tidyee class object |
... |
other arguments |
sliced/filtered image or imageCollection form filtered imageCollection
slice
for information about slice on normal data tables.
## Not run: library(rgee) library(tidyrgee) ee_Initialize() l8 = ee$ImageCollection('LANDSAT/LC08/C01/T1_SR') l8 |> filter(date>"2016-01-01",date<"2016-03-04") # example with tidyee ckass modis_ic <- ee$ImageCollection("MODIS/006/MOD13Q1") modis_ic_tidy <- as_tidyee(modis_ic) # filter by month modis_march_april <- modis_ic_tidy |> filter(month %in% c(3,4)) ## End(Not run)
## Not run: library(rgee) library(tidyrgee) ee_Initialize() l8 = ee$ImageCollection('LANDSAT/LC08/C01/T1_SR') l8 |> filter(date>"2016-01-01",date<"2016-03-04") # example with tidyee ckass modis_ic <- ee$ImageCollection("MODIS/006/MOD13Q1") modis_ic_tidy <- as_tidyee(modis_ic) # filter by month modis_march_april <- modis_ic_tidy |> filter(month %in% c(3,4)) ## End(Not run)
Summary pixel-level stats for ee$ImageCollection or tidyrgee objects with ImageCollections
## S3 method for class 'ee.imagecollection.ImageCollection' summarise(.data, stat, ...) ## S3 method for class 'tidyee' summarise(.data, stat, ..., join_bands = TRUE)
## S3 method for class 'ee.imagecollection.ImageCollection' summarise(.data, stat, ...) ## S3 method for class 'tidyee' summarise(.data, stat, ..., join_bands = TRUE)
.data |
ee$Image or ee$ImageCollection |
stat |
|
... |
other arguments |
join_bands |
|
ee$Image or ee$ImageCollection where pixels are summarised by group_by and stat
ee$Image or ee$ImageCollection where pixels are summarised by group_by and stat
ee$Image or ee$ImageCollection where pixels are summarised by group_by and stat
summarise
for information about summarise on normal data tables.
## Not run: library(tidyrgee) library(rgee) ee_Initialize() modis_ic <- ee$ImageCollection("MODIS/006/MOD13Q1") modis_ic |> filter(date>="2016-01-01",date<="2019-12-31") |> group_by(year) |> summarise(stat="max") ## End(Not run)
## Not run: library(tidyrgee) library(rgee) ee_Initialize() modis_ic <- ee$ImageCollection("MODIS/006/MOD13Q1") modis_ic |> filter(date>="2016-01-01",date<="2019-12-31") |> group_by(year) |> summarise(stat="max") ## End(Not run)