generate_pa_target_group: Generate Pseudo-Absences Using Target-Group Background

View source: R/generate_pseudo_absences.R

generate_pa_target_groupR Documentation

Generate Pseudo-Absences Using Target-Group Background

Description

Generate Pseudo-Absences Using Target-Group Background

Usage

generate_pa_target_group(
  presences,
  target_group_points,
  study_area,
  raster_stack,
  predictor_variables,
  coords = c("decimalLongitude", "decimalLatitude"),
  ratio = 1,
  attempts = 100,
  seed = NULL
)

Arguments

presences

Data frame containing presence points.

target_group_points

Data frame of all sampling locations (target group).

study_area

Spatial polygon defining the study area ('sf' object).

raster_stack

'SpatRaster' object containing covariate data.

predictor_variables

Character vector of the predictor variables selected for this species.

coords

Character vector specifying the column names for latitude and longitude. Defaults to 'c("decimalLongitude", "decimalLatitude")'.

ratio

Ratio of pseudo-absences to presences (default 1 = balanced).

attempts

Integer specifying the number of attempts to generate exact pseudo-absences. Defaults to 100.

seed

Optional random seed.

Value

Data frame containing pseudo-absence points with coordinates, timestamp, pa = 0, and covariates.


glossa documentation built on June 8, 2025, 1:20 p.m.