distg function

Distance matrix with geometric anisotropy

Distance matrix with geometric anisotropy

The function computes the distance between locations, with geometric anisotropy. The parametrization assumes there is a scale parameter, say σ\sigma, so that scale

is the distortion for the second component only. The angle rho must lie in [π/2,π/2][-\pi/2, \pi/2]. The dilation and rotation matrix is [REMOVE_ME](cos(ρ)sin(ρ)σsin(ρ)σcos(ρ))[REMOVEME2] \left(\begin{matrix} \cos(\rho) & \sin(\rho) \\ - \sigma\sin(\rho) & \sigma\cos(\rho) \end{matrix} \right) [REMOVE_ME_2]

distg(loc, scale, rho)

Arguments

  • loc: a d by 2 matrix of locations giving the coordinates of a site per row.
  • scale: numeric vector of length 1, greater than 1.
  • rho: angle for the anisotropy, must be larger than π/2\pi/2 in modulus.

Returns

a d by d square matrix of pairwise distance

Description

The function computes the distance between locations, with geometric anisotropy. The parametrization assumes there is a scale parameter, say σ\sigma, so that scale

is the distortion for the second component only. The angle rho must lie in [π/2,π/2][-\pi/2, \pi/2]. The dilation and rotation matrix is

(cos(ρ)sin(ρ)σsin(ρ)σcos(ρ)) \left(\begin{matrix} \cos(\rho) & \sin(\rho) \\ - \sigma\sin(\rho) & \sigma\cos(\rho) \end{matrix} \right)