Last data update: 2014.03.03

R: Function for making a data frame summarising residency and...
scheduleR Documentation

Function for making a data frame summarising residency and movement pattern.

Description

Function for making a data frame summarising residency and movement pattern.

Usage

schedule(tFirst, tSecond, site)

Arguments

tFirst

date and time of sunrise/sunset (e.g. 2008-12-01 08:30)

tSecond

date and time of sunrise/sunset (e.g. 2008-12-01 17:30)

site

a vector, indicating the residency period of a particular day (see output: changeLight)

Value

A data.frame with end and start date (yyyy-mm-dd hh:mm, UTC) for each stationary period.

Author(s)

Simeon Lisovski

Examples

data(hoopoe2)
  hoopoe2$tFirst <- as.POSIXct(hoopoe2$tFirst, tz = "GMT")
  hoopoe2$tSecond <- as.POSIXct(hoopoe2$tSecond, tz = "GMT")
residency <- changeLight(hoopoe2, rise.prob=0.1, set.prob=0.1, plot=FALSE, summary=FALSE)
schedule(hoopoe2[,1], hoopoe2[,2], site = residency$site)

Results


R version 3.3.1 (2016-06-21) -- "Bug in Your Hair"
Copyright (C) 2016 The R Foundation for Statistical Computing
Platform: x86_64-pc-linux-gnu (64-bit)

R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.

R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.

Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.

> library(GeoLight)
Loading required package: maps

 # maps v3.1: updated 'world': all lakes moved to separate new #
 # 'lakes' database. Type '?world' or 'news(package="maps")'.  #


> png(filename="/home/ddbj/snapshot/RGM3/R_CC/result/GeoLight/schedule.Rd_%03d_medium.png", width=480, height=480)
> ### Name: schedule
> ### Title: Function for making a data frame summarising residency and
> ###   movement pattern.
> ### Aliases: schedule
> 
> ### ** Examples
> 
> data(hoopoe2)
>   hoopoe2$tFirst <- as.POSIXct(hoopoe2$tFirst, tz = "GMT")
>   hoopoe2$tSecond <- as.POSIXct(hoopoe2$tSecond, tz = "GMT")
> residency <- changeLight(hoopoe2, rise.prob=0.1, set.prob=0.1, plot=FALSE, summary=FALSE)
> schedule(hoopoe2[,1], hoopoe2[,2], site = residency$site)
  Site             Arrival           Departure
1    a                <NA> 2008-07-30 00:01:00
2    b 2008-07-15 23:34:00 2008-09-11 00:25:00
3    c 2008-07-31 00:15:00 2008-09-12 00:37:30
4    d 2008-09-12 12:27:30                <NA>
> 
> 
> 
> 
> 
> dev.off()
null device 
          1 
>