genHaversineMat: A function to generate a Haversine matrix from a dataframe

Description Usage Arguments Value Examples

View source: R/antarcticR.R

Description

Generate a distance matrix of great-circle distances from a dataframe with longitude and latitude distances

Usage

1

Arguments

df

Your data frame

Value

A haversine distance matrix

Examples

1
2
3
4
5
6
points <- read.csv("dividedEvents1.csv",header=T, sep=",")
df.points <- as.matrix(points)
antFrame = data.frame(df.points)
print("Computing distance matrix...")
require(geosphere)
d  <- genHaversineMat(antFrame)

LukeBatten/antarcticR documentation built on Aug. 22, 2017, 12:29 a.m.