Given a set of cartesian coordinates representing an object's trajectory, this function builds a trajectory table that can then be used to work with the functions provided by the swaRm package.

makeTraj(x, y, z = NULL, id = NULL, date = NULL, time = NULL,
start_time = NULL, tz = NULL, fps = NULL, date.format = "ymd",
time.format = "hms", geo = FALSE)

## Arguments

x A vector of x (or longitude) coordinates corresponding to a single animal trajectory. A vector of y (or latitude) coordinates corresponding to a single animal trajectory. A vector of z (or altitude) coordinates corresponding to a single animal trajectory (default: NULL). A unique identifier for the trajectory. It can be a number or a character string. If not set, it defaults to zero. A character string corresponding to a date in year-month-day format. Alternatively, a vector of character strings of the same length as x and y (for instance if the trajectory spans multiple days). If not set, it default to January 1st, 1970. A vector of character strings corresponding to the timestamps of each location of the trajectory, in hours-minutes-seconds format. If not set, the first timestamp defaults to 0 hours, 0 minutes, 1 second. The following timestamps are either in increment of 1 second or 1 second / fps. The time at which tracking began. It can be any object that can be converted to a date-time by as_datetime. If not specified, it defaults to the date-time returned by now. A character string identifying the timezone of the timestamps of the trajectory. Default: "UTC". A single numeric value corresponding to the sampling rate of the trajectory. A character string with 3 letters ('y' for year, 'm' for month, and 'd' for day) indicating the format of the date (e.g., 'ymd' for year-month-day, 'dmy' for day-month-year, etc). A character string with 2 or 3 letters ('h' for hour, 'm' for minute, and 's' for second) indicating the format of the time (e.g., 'hms' for hour-minute-second, 'hm' for hour-minute, and 'ms' for minute-second). A logical value indicating whether the locations are defined by geographic coordinates (pairs of longitude/latitude values). Default: FALSE.

## Value

A trajectory table.

## Examples

# TODO