get.lu.ecors: Get Land Use data to ecors

View source: R/get.lu.ecors.R

get.lu.ecorsR Documentation

Get Land Use data to ecors

Description

Get Land Use data from Google Earth Engine for your study site and integrate with study polygons.

Usage

get.lu.ecors(
  site = NULL,
  points = NULL,
  plots = NULL,
  polygons = NULL,
  id.column = 1,
  projected = FALSE,
  custom.crs = NULL,
  collection.lu = "mapbiomas6",
  years,
  resolution = 30,
  evaluate,
  buffer1 = 0,
  buffer2 = 0,
  buffer3 = 0,
  cumulative.surroundings = F,
  online.storage = "drive"
)

Arguments

site

polygon of study site (sf object). Evaluation carried out in the surroundings of this polygon.

points

sampling points (sf object). Evaluation carried out in the surroundings of these polygons.

plots

sampling plots (sf object). Evaluation carried out in the surroundings of these points.

polygons

polygon for land use evaluation. Evaluation carried out inside these polygons.

id.column

number of id.column in your points, plots or polygons objects (need to be the same for all).

projected

are the provided sf objects projected? (scale = m)

custom.crs

choose a crs code to project sf objects prior to buffer processing.

collection.lu

Land Use collection. Available options are currently "mapbiomas5" and "mapbiomas6" (MapBiomas collections 5 and 6). Select the most recent (higher number) if there is no reason not to.

years

numerical vector.

resolution

select pixel size (m) for analysis and download.

evaluate

indicate whether analysis should be performend on the "surroundings.samples", "surroundings.site" or "inside.polygons". Option "distance.samples" should be used when you want to use only the dist.lu.ecors function where buffers are not used (other options of the evaluate argument do not preclude the usage of dist.lu.ecors).

buffer1

nearest buffer radius (m).

buffer2

middle buffer radius (m).

buffer3

farthest buffer radius (m).

cumulative.surroundings

should the area of each buffer be cumulative with those contained in them? (buffer3 should contain buffer2? buffer2 should contain buffer1?)

online.storage

select online storage integration (mandatory for images download). Options are "drive" for Google Drive, "gcs" for Google Cloud Storage or NULL.

Details

Sites, plots and points represent places where you want to know the effect of land use carried out in the surroundings (buffer zones). If you want to define the area within which the land use will be evaluated, use the polygons option. For site, points and parcels it is necessary to inform at least one buffer size.
Regardless of where you want to perform the analyses, all these geometries can be informed simultaneously so that these polygons can be used in the map visualization.

Value

Object of the "lu.ecors" class with metadata and pre-processed data to be used in the count.lu.ecors, dist.lu.ecors, plot.focal.lu.ecors, plot.lu.ecors or download.lu.ecors functions. Aditional Google Earth Engine container object lu (Land Use image: years stored as bands) is exported to .GlobalEnv to be used in rgee functions and avoid errors (elapsed time limit).

Examples

FAL.IBGE.JBB<-sf::st_read(system.file("extdata/FAL.IBGE.JBB.gpkg", package="ecors"))
test.points<-sf::st_read(system.file("extdata/Points_tests.gpkg", package="ecors"))
test.plots<-sf::st_read(system.file("extdata/Plots_tests.gpkg", package="ecors"))

# Get data (projecting to UTM 32S zone to performe buffer operations)
lu2000_2010<-get.lu.ecors(site=FAL.IBGE.JBB, points=test.points, plots=test.plots,
     polygons=NULL, id.column=1, projected=F, custom.crs=32723,
     collection.lu="mapbiomas6", years=c(2000,2010), resolution=30, evaluate="surroundings.site",
     buffer1=5000, buffer2=10000, buffer3=NULL, cumulative.surroundings=F)



fredtaka/ecors documentation built on Aug. 26, 2022, 6:58 a.m.