ggplot_tracks: ggplot wrapper for tracks objects.

Description Usage Arguments Value Examples

View source: R/tracks_plots.R

Description

Instead of using one of the more streamlined plotting functions such as plot_tracks, this wrapper gives full control over the visualization. All it does, is select a table from the tracks object, and pull it from the nodes if necessary.

Usage

1

Arguments

tracks

A tracks object.

table

Which table is plotting. Give the name as a character vector, e.g. 'tr'.

...

Arguments to be passed on to ggplot.

Value

A ggplot object.

Examples

1
2
3
4
5
if (require(ggplot2)){
  tr <- as_tracks(guppies, 30, 1080)
  ggplot_tracks(tr, 'tr', aes(X, Y, col = animal)) +
    geom_path() + facet_wrap(~trial)
}

Ax3man/trackr documentation built on Oct. 8, 2019, 10:53 p.m.