envelope function (spatstat) - error "unused arguments" -
envelope function (spatstat) - error "unused arguments" -
i inquire help finding reason why when utilize function envelope, arguments not accepted, defined "unused arguments". info i'm using ppp without marks , create l function graph simulated info , data. here code ppp data:
map2008mlw = ppp(xy2008_bngppp$x, xy2008_bngppp$y, window = iom_polygon_mlwowin)
and then:
l2008 = lest(map2008mlw,correction="ripley") op = par(mar=c(5,5,4,4)) plot(l2008, . -r ~ r, ylab=expression(hat("l")), xlab = "d (m)"); par(op) l2008$iso = l$iso - l$r l2008$theo = l$theo - l$r
desired number of simulations
n = 9999
desired p significance level display
p = 0.05
and @ point envelope function doesnt seem happy:
el2008 = envelope(map2008mlw[w], lest, nsim=n, rank=(p * (n + 1))) error in envelope(map2008mlw[w], lest, nsim = n, rank = (p * (n + 1))) : unused arguments (nsim = n, rank = (p * (n + 1)))
it seems generic error , not sure caused bundle spatstat. please, help me in finding solution this, can't proceed analyses.
thank much,
martina
the argument rank
should nrank
.
also relationship between significance level , argument nrank
not right in example. two-sided test, significance level alpha = 2 * nrank/(nsim+1)
, nrank= alpha * (nsim+1)/2
.
you have chosen significance level of 0.95 assume mean 0.05. nsim=9999
want nrank=0.05 * 10000/2 = 250
test significance level 0.05.
such big number of simulations (9999) unnecessary in kind of application. monte carlo tests valid little values of nsim
. in illustration utilize nsim=39
, nrank=1
.
see chapter 10 of the spatstat book.
arguments envelope spatstat
Comments
Post a Comment