pathToSphericalData: Find the spherical data for a given path

View source: R/TrajectoryGeometry.R

pathToSphericalDataR Documentation

Find the spherical data for a given path

Description

This function takes a path and returns a list containing its projection to the sphere, the center for that projection, the spherical distance from the center to the points of the projection and the name of the statistic used.

Usage

pathToSphericalData(path, from, to, d, statistic)

Arguments

path

- This is an mxn dimensional matrix. Each row is considered a point.

from

- The starting place along the path which will be treated as the center of the sphere. This defaults to 1.

to

- The end point of the path. This defaults to nrow(path).

d

- The dimension under consideration. This defaults to ncol(path)

statistic

- One of 'median', 'mean' or 'max'

Value

This function returns a list whose elements are the projections of the path to the sphere, the center for those projections, the median, mean or max distance from the center to those projections and the name of the statistic used.

Examples

sphericalData = pathToSphericalData(straight_path,from=1,
                                    to=nrow(straight_path), d=3,
                                    statistic='median')

AnnaLaddach/TrajectoryGeometry documentation built on Oct. 18, 2024, 5:57 p.m.