Description Usage Arguments Value Author(s) Examples
View source: R/lucC_result_measures.R
Provide a data.frame with count of categorical variables from a list of data.frame derived of processing with many blocks of RasterBricks
1 | lucC_extract_frequency (data_mtx.list = NULL, cores_in_parallel = 1)
|
data_mtx.list |
Matrix. A list of matrix with values obtained from predicates RECUR, EVOLVE, CONVERT or HOLDS for each block of RasterBrick |
cores_in_parallel |
Integer. Number of cores to use, in other words the amount of child processes will be run simultaneously. Default is 1 core, that means no one parallelization. |
Data frame with statistical measures
Adeline M. Maciel
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 | ## Not run:
library(lucCalculus)
file <- c(system.file("extdata/raster/rasterSample.tif", package = "lucCalculus"))
rb_class <- raster::brick(file)
my_label <- c("Degradation", "Fallow_Cotton", "Forest", "Pasture", "Soy_Corn", "Soy_Cotton",
"Soy_Fallow", "Soy_Millet", "Soy_Sunflower", "Sugarcane", "Urban_Area", "Water")
my_timeline <- c("2001-09-01", "2002-09-01", "2003-09-01", "2004-09-01", "2005-09-01",
"2006-09-01", "2007-09-01", "2008-09-01", "2009-09-01", "2010-09-01",
"2011-09-01", "2012-09-01", "2013-09-01", "2014-09-01", "2015-09-01",
"2016-09-01")
# list empty to store the holds operations
data.list <- list(NULL)
data.list[[1]] <- lucC_pred_holds(raster_obj = rb_class, raster_class = "Pasture",
time_interval = c("2001-09-01","2016-09-01"),
label = my_label, timeline = my_timeline)
data.list[[2]] <- lucC_pred_holds(raster_obj = rb_class, raster_class = "Degradation",
time_interval = c("2001-09-01","2016-09-01"),
label = my_label, timeline = my_timeline)
data.list
# extract frequency from list data
d <- lucC_extract_frequency(data_mtx.list = data.list, cores_in_parallel = 2)
# use the frequency extracted from list
lucC_result_measures(data_frequency = d, pixel_resolution = 232)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.