data(paracou16)
# Keep only 20% of points to run this example
X <- as.wmppp(rthin(paracou16, 0.2))
autoplot(X)
# Plot the envelope (should be 1000 simulations, reduced to 20 to save time)
autoplot(KdEnvelope(X, ReferenceType="Q. Rosea", NumberOfSimulations=20))
# With a formula and a compact legend
autoplot(KEnvelope(X, NumberOfSimulations=20),
./(pi*r^2) ~ r,
LegendLabels=c("Observed", "Expected", "Confidence\n enveloppe"))
Run the code above in your browser using DataLab