bayes_read_probs {bayesEO}R Documentation

Read probability maps

Description

Read probability maps

Usage

bayes_read_probs(probs_file, labels)

Arguments

probs_file

Full path to raster multi-band file containing probability matrices

labels

Labels to be assigned to the bands

Value

A SpatRaster object

Author(s)

Gilberto Camara, gilberto.camara@inpe.br

Examples

if (bayes_run_examples()) {
# Define location of a probability file
data_dir <- system.file("/extdata/probs", package = "bayesEO")
# list the file
file <- list.files(data_dir)
# build the full path
probs_file <- paste0(data_dir, "/", file)
# define labels
labels <- c("Water", "ClearCut_Burn", "ClearCut_Soil",
             "ClearCut_Veg", "Forest", "Wetland")

probs_image <- bayes_read_probs(probs_file, labels)
}

[Package bayesEO version 0.2.1 Index]