projectDimensions: Extract Spatial Dimensions

Description Usage Arguments Value Examples

View source: R/track-set-transformations.R

Description

Projects tracks onto the given spatial dimensions.

Usage

1
projectDimensions(x, dims = c("x", "y"))

Arguments

x

the input tracks object.

dims

a character vector (for column names) or an integer vector (for column indices) giving the dimensions to extract from each track. The time dimension (i.e., the first column of all tracks) is always included.

Value

A tracks object is returned that contains only those dimensions of the input tracks that are given in dims.

Examples

1
2
3
## Compare 2D and 3D speeds
speed.2D <- mean( sapply( subtracks( projectDimensions( TCells, c("x","z") ), 2 ), speed ) )
speed.3D <- mean( sapply( TCells, speed ) )

jtextor/MotilityLab documentation built on May 20, 2019, 3:13 a.m.