Library: | spatial |
See also: | SPPPinit SPPPinitrandom SPPPsetregion SPPPgetregion SPPPkfn SPPPpsim SPPPstrauss SPPPssi SPPPkaver |
Quantlet: | SPPPkenvl | |
Description: | computes envelope (upper and lower limits) and average of simulations of K-fns |
Usage: | res = SPPPkenvl(fs, k, obj) | |
Input: | ||
fs | scalar, full scale of the plot | |
k | scalar, number of regularly spaced distances in (0, fs) | |
obj | list, consisting of xmat, ymat, and type, caculated by SPPPpsim, SPPPstrauss, or SPPPssi (list type = "PSIM", "STRAUSS", or "SSI") | |
Output: | ||
res | list, consisting of components hx, hl, hu and aver: | |
res.hx | k x 1 vector, distances | |
res.hl | k x 1 vector, min of K-fn | |
res.hu | k x 1 vector, max of K-fn | |
res.aver | k x 1 vector, averages of K-fn |
; loads the spatial statistics library library("spatial") ; reads a spatial data set pines = read("pines.dat") ; initializes a point process pinesobj = SPPPinit(pines, 0, 96, 0, 100, 10) ; resets random number generator SPPPinitrandom(0) ; simulates 100 Binomial point processes, each consisting ; of 72 points, in the previously determined domain ppsim = SPPPpsim(100, 72) ; calculates the envelope in interval(0, 5), split ; into 100 segments ppkenvl = SPPPkenvl(5, 100, ppsim) ppkenvl
List consisting of distances and min, max, and averages of K-fn: Contents of ppkenvl.hx [ 1,] 0.05 [ 2,] 0.1 [ 3,] 0.15 ... [ 99,] 4.95 [100,] 5 Contents of ppkenvl.hl [ 1,] 0 [ 2,] 0 [ 3,] 0 ... [ 99,] 4.6822 [100,] 4.7263 Contents of ppkenvl.hu [ 1,] 0.15355 [ 2,] 0.21716 [ 3,] 0.26596 ... [ 99,] 5.1452 [100,] 5.204 Contents of ppkenvl.aver [ 1,] 0.049757 [ 2,] 0.096131 [ 3,] 0.15146 ... [ 99,] 4.9111 [100,] 4.9623