PathPlot function

Path plot of BCPA output

Path plot of BCPA output

Plots the animal's trajectory, with segments color-coded according to the time scale / auto-correlation of the BCPA output, and width of segments proportional to the estimated mean of the BCPA.

PathPlot( Data, windowsweep, type = c("smooth", "flat")[1], clusterwidth = 1, plotlegend = FALSE, tauwhere = "topleft", n.legend = 5, ncol.legend = 1, bty.legend = "n", ... )

Arguments

  • Data: the track data to be plotted - most typically, output of the GetVT function.
  • windowsweep: windowsweep object, i.e. the output of the WindowSweep function.
  • type: whether to plot smooth or flat bcpa output
  • clusterwidth: for flat BCPA, this is the temporal range within which change points are considered to be within the same cluster.
  • plotlegend: whether to plot a legend.
  • tauwhere: where to place the legend for the time-scale / auto-correlation. Can be one of "nowhere", "top", "bottom", "left", "right", "topleft", "topright", "bottomright", "bottomleft".
  • n.legend: number of labels in legend.
  • ncol.legend: number of columns in the legend.
  • bty.legend: whether to draw a box around the legend.
  • ...: additional arguments to pass to the plot base function.

Examples

if(!exists("Simp.ws")) { data(Simp) Simp.ws <- WindowSweep(GetVT(Simp), "V*cos(Theta)", windowsize = 50, windowstep = 1, progress=TRUE) } PathPlot(Simp, Simp.ws, plotlegend=TRUE, n.legend=3) PathPlot(Simp, Simp.ws, type="flat", clusterwidth=3, plotlegend=TRUE)

Author(s)

Eliezer Gurarie

  • Maintainer: Eliezer Gurarie
  • License: Unlimited
  • Last published: 2022-05-30

Useful links