pseudoRandomQuad: psuedoRandomQuad

View source: R/weights_pseudo.R

pseudoRandomQuadR Documentation

psuedoRandomQuad

Description

A relatively quick way to generate psuedo-random quadrature set for ppm models.

Usage

pseudoRandomQuad(npoints, window, coord = c("X", "Y"), control)

Arguments

npoints

The number of background points to use. The default is 1000, but it is generally recommended to use more when fitting a ppm.

window

A SpatRaster from terra package which will represent the extent and resolution of the point process model.

coord

The names of the coordinates. Default is c("X","Y").

control

A list of control options passed from ppmData

Author(s)

Skipton Woolley

Examples

library(ppmData)
library(terra)
path <- system.file("extdata", package = "ppmData")
lst <- list.files(path=path,pattern='*.tif',full.names = TRUE)
window <- rast(lst[1])
res <- pseudoRandomQuad(10000,window,control=list(quiet=FALSE))
plot(window)
points(res[,1:2],pch=".")

skiptoniam/qrbp documentation built on May 13, 2023, 2:08 a.m.