https://github.com/cran/spatstat
Raw File
Tip revision: 13ad06cde7def3c6afc6638d08053f24ccc97a24 authored by Adrian Baddeley on 24 November 2005, 18:48:08 UTC
version 1.8-1
Tip revision: 13ad06c
eem.R
# eem.R
#
# Computes the Stoyan-Grabarnik "exponential energy weights" 
#
# $Revision: 1.1 $ $Date: 2005/05/11 19:49:02 $
#

eem <- function(fit) {
  verifyclass(fit, "ppm")
  lambda <- fitted.ppm(fit)
  Q <- quad.ppm(fit)
  Z <- is.data(Q)
  eemarks <- 1/lambda[Z]
  attr(eemarks, "type") <- "eem"
  attr(eemarks, "typename") <- "exponential energy marks"
  return(eemarks)
}
back to top