tangentVectors: Calculate the tangent cectors of a trajectory object

View source: R/tangentVectors.R

tangentVectorsR Documentation

Calculate the tangent cectors of a trajectory object

Description

This function calculates the unit tangent vectors at each point of the trajectory represented by a 'trajectory' object. The tangent vectors are computed by taking the difference between consecutive points and normalizing them to have unit length.

Usage

tangentVectors(obj)

Arguments

obj

An object of class 'trajectory' that contains a component 'points'.

Value

A matrix where each row is a unit tangent vector corresponding to each pair of consecutive points in 'obj$points'.


BioTrajectory documentation built on Nov. 26, 2025, 5:07 p.m.