lambda: intensity object suitable for use in Cox simulation

View source: R/lambda.R

lambdaR Documentation

intensity object suitable for use in Cox simulation

Description

intensity object suitable for use in Cox simulation

Usage

lambda(
  x,
  kernel = "gauss",
  sigma = 0.5,
  type = "sum",
  alpha = 1,
  weights = NULL
)

Arguments

x

matrix of coordinates

kernel

type of kernel to use, "gauss" or "step"

sigma

kernel parameter, sd of gauss or range of step

type

"sum" or "product", see details

alpha

additional scaling parameter

weights

If a vector of length nrow(x), weight the sum/prod with these weights

Details

For type="sum", the field is

v(u) = alpha * sum k(u-x)

where k is a kernel, and type="product"

v(u) = exp(alpha[1]) * prod [ 1 + alpha[2]*k(u-x)/k(0) ]

following Jalilian et al. 2015. The kernels are normalised densities in the dimension of x.

This function merely creates an field object. Use "coxintensity2matrix" to evaluate it at arbitrary locations, or "rcox" to simulate uniform/poisson process on it.


antiphon/rcox documentation built on June 3, 2023, 11:07 a.m.