xytb-methods: xytb class constructor

Description Usage Arguments Value Methods' signature Author(s) Examples

Description

The methods to build an xytb object (see xytb-class for the class description).

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
xytb(object, desc, winsize, idquant, move, ...)

## S4 method for signature 'missing,missing,ANY,ANY,ANY'
xytb(desc = "null xybt object")

## S4 method for signature 'data.frame,character,ANY,ANY,ANY'
xytb(object, desc, winsize,
  idquant, move, ...)

## S4 method for signature 'data.frame,character,vector,vector,ANY'
xytb(object, desc, winsize,
  idquant, move, ...)

## S4 method for signature 'data.frame,character,vector,vector,vector'
xytb(object,
  desc = "unknow track", winsize = seq(3, 13, 2), idquant = seq(0, 1,
  0.25), move = c(5, 10), ...)

Arguments

object

a data frame with 5 columns

id individual id character
x longitude decimal degree
y latitude decimal degree
t date and time POSIXct
b behaviour character
desc

vector of character describing the dataset

winsize

a numerical vector giving the length of the windows used to calculate moving standard deviation, average, mad and quantile for the speed (v), the distance (dist) and the relative angle (thetarel).

idquant

a numerical vector giving the quantiles to be calculated. For example if idquant=c(0,0.25,.5,1), the quantiles at 0% (min), 25% (first quartile), 50% (median) and 100% (max) will be calculated.

move

a numerical vector providing the shift used to computed parameters back in time. For example if move=c(5,10,100), the parameters will be shifted backward by 5, 10 and 100 locations. Optional.

...

part of the generic definition

Value

an xytb object

Methods' signature

Author(s)

Laurent Dubroca

Examples

1
2
3
4
5
6
7
8
9
#generate an empty xytb object
xytb()
#generate an xytb object with track information only
#track_CAGA_005 is a dataset
simplexytb<-xytb(track_CAGA_005,"a track")
#generate a complete xytb object with derived (over moving windows of 3, 5
#and 9 points, with quantile at 0, 50 and 100%) and shifted information on 10
#and 100 points
xytb<-xytb(track_CAGA_005,"a track",c(3,5,9),c(0,.5,1),c(10,100))

m2b documentation built on May 2, 2019, 10:22 a.m.