disc_stats: Compute statistics (circular and activity-level) on a...

Description Usage Arguments See Also Examples

View source: R/disc_stats.R

Description

Compute statistics (circular and activity-level) on a deployment's trajectory data and create plots

Usage

1
disc_stats(dir, bin.angle = 0, sub = NULL, verbose = FALSE, ...)

Arguments

dir

path the to the deployment directory

bin.angle

precision at which to bin angles

sub

subsample positions every sub seconds to make them independent

verbose

output messages on the console when TRUE

...

passthrough argument

See Also

summary.circular for a description of the output statistics.

Other action.functions: disc_calibrate, disc_camera_compass_angle, disc_correct, disc_track_compass, disc_track, disc

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
# get example deployments included with the package
deploys <- system.file("extdata", "deployments", package = "discr")
# copy them to a writable, temporary directory
temp <- tempdir()
file.copy(deploys, temp, recursive=TRUE)
dd <- paste0(temp, "/deployments/")
deploy1 <- paste0(dd, "1")

# run the action
disc_conf(deploy.dir=dd)
disc_stats(dir=deploy1, verbose=TRUE)
# inspect results
list.files(deploy1)
read.csv(paste0(deploy1, "/stats.csv"))

# subsample positions
disc_stats(dir=deploy1, sub=10, verbose=TRUE)
read.csv(paste0(deploy1, "/stats.csv"))
# Note the difference in n compared to above

jiho/discr documentation built on May 19, 2019, 9:30 a.m.