CheckDistance: Checking Distance Type

View source: R/Utility.r

CheckDistanceR Documentation

Checking Distance Type

Description

Checks the validity and type of the specified distance.

Usage

CheckDistance(distance)

Arguments

distance

A character string indicating the type of distance. Available options are: "Eucl" (Euclidean), "Geod" (Geodesic), and "Chor" (Chordal). See also GeoCovmatrix.

Details

This function checks whether the specified distance type is valid.

Value

An integer:

  • 0 for Euclidean distance

  • 1 for Geodesic distance

  • 2 for Chordal distance

If the input is not recognized, the function returns NULL.

Author(s)

Moreno Bevilacqua moreno.bevilacqua89@gmail.com
https://sites.google.com/view/moreno-bevilacqua/home
Víctor Morales Oñate victor.morales@uv.cl
https://sites.google.com/site/moralesonatevictor/
Christian Caamaño-Carrillo chcaaman@ubiobio.cl
https://www.researchgate.net/profile/Christian-Caamano


GeoModels documentation built on June 25, 2025, 5:10 p.m.