simulate_antecedent_conditions: simulate_antecedent_conditions

Description Usage Arguments Details Value References See Also Examples

View source: R/simulate_antecedent_conditions.R

Description

Simulate heterogenous pattern

Usage

1
simulate_antecedent_conditions(x, i, j, nsim, heterogenous = FALSE, ...)

Arguments

x

ppp

i

Mark of points that are randomized.

j

Mark of points that do not change.

nsim

Number of patterns to simulate.

heterogenous

If TRUE, points with the mark i are randomized using a heterogeneous Poisson process.

...

Arguments passed to spatstat.core::density.ppp().

Details

Simulate point patterns as null model data for spatstat.core::envelope() using antecedent conditions as null model. x must be marked point pattern. Antecedent conditions are suitable as a null model if points of type j may influence points of type i, but not the other way around (Velazquez et al 2016). One example are the positions of seedlings that may be influenced by the position of mature trees.

Returns a list with ppp objects.

Value

list

References

Velázquez, E., Martínez, I., Getzin, S., Moloney, K.A., Wiegand, T., 2016. An evaluation of the state of spatial point pattern analysis in ecology. Ecography 39, 1–14. https://doi.org/10.1111/ecog.01579

Wiegand, T., Moloney, K.A., 2014. Handbook of spatial point-pattern analysis in ecology. Chapman and Hall/CRC Press, Boca Raton.

See Also

envelope

Examples

1
2
3
4
5
6
7
8
9
set.seed(42)
pattern_a <- spatstat.core::runifpoint(n = 20)
spatstat.geom::marks(pattern_a) <- "a"
pattern_b <- spatstat.core::runifpoint(n = 100)
spatstat.geom::marks(pattern_b) <- "b"
pattern <- spatstat.geom::superimpose(pattern_a, pattern_b)

null_model <- simulate_antecedent_conditions(x = pattern, i = "b", j = "a", nsim = 19)
spatstat.core::envelope(Y = pattern, fun = spatstat.core::pcf, nsim = 19, simulate = null_model)

onpoint documentation built on Sept. 9, 2021, 9:07 a.m.