[R] envelopes of simulations

2006-01-15 Thread Adrian Baddeley

Sara Mouro writes:
  Hello!
  
  I am writing you because I could not plot the confidence envelopes for
  functions Jest, Jcross, Jdot, Jmulti, and L, using the Spatstat package.

Enquiries about a package should be sent to the package maintainer
rather than R-help. 

  I have already understood how to do that for Kest or Jest, that is:
  JEnv - plot(envelope(PPPData, Jest))
   Where PPPData is my ppp object.
  
  However, for Jcross I must specify the two marks I want to analyse.
  That is, usually I would get the Jcross doing:
  Jc - Jcross(PPPData,Aun,Qsu)
   For marks Aun and Qsu.

To do this, type
  envelope(PPPData, Jcross, i=Aun, j=Qsu)

Explanation:
Looking at help(Jcross) we see that its formal syntax is 
Jcross(X, i, j). 
This means that when you call 
Jcross(PPPData,Aun,Qsu)
the arguments are matched as 
Jcross(X=PPPData,i=Aun,j=Qsu).

So our problem is, how to pass the argumentsi=Aun and j=Qsu
to the function Jcross each time it is called by `envelope'.

The help entry for 'envelope' mentions that `envelope' will accept 
extra arguments ... which are then passed to the function 'fun'.

So, to pass the two argument values i=Aun and j=Qsu,
just type
 envelope(PPPData, Jcross, i=Aun, j=Qsu)

  For L function, I can make:
  K - Kest (PPPData, correction=isotropic)
  plot (K, r-sqrt(iso/pi)~r)

You can compute the envelope for the K-function
and transform it afterwards. 

To plot envelopes of the L function discrepancy
   LD(r) = sqrt(K(r)/pi) - r,
just type 
E - envelope(PPPData, Kest, correction=isotropic)
plot(E, sqrt(./pi) -r ~ r)

Hope this helps.
regards
Adrian Baddeley

__
R-help@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html


[R] envelopes of simulations

2006-01-12 Thread Sara Mouro
Hello!

I am writing you because I could not plot the confidence envelopes for
functions Jest, Jcross, Jdot, Jmulti, and L, using the Spatstat package.

I have already understood how to do that for Kest or Jest, that is:
JEnv - plot(envelope(PPPData, Jest))
Where PPPData is my ppp object.


However, for Jcross I must specify the two marks I want to analyse.
That is, usually I would get the Jcross doing:
Jc - Jcross(PPPData,Aun,Qsu)
For marks Aun and Qsu.


For L function, I can make:
K - Kest (PPPData, correction=isotropic)
plot (K, r-sqrt(iso/pi)~r)


But I could not understand how to put all that together. 

Resuming, I do not understand how can I use the envelope function:
-   to plot Jcross (where and how do I specify types/marks ??)
-   to plot L (where do I write that I do not want K, but
r-sqrt(iso/pi)~r, instead??)
-   etc. for similar functions not so simple as Jest, Kest or Gest. 

Hope someone can please help me on this.
I have already looked at the package's manual, but I could not find any
example similar to what I am trying to do.


Best Regards,
Sara Mouro.






[[alternative HTML version deleted]]

__
R-help@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html