DSI | R Documentation |
DSI ("dyadic CSI")
DSI( b.source, from = NULL, to = NULL, behaviours = NULL, ot.source = NULL, ot.type = "table", duration.NA.treatm = "omit", presence = NULL, directed = FALSE, onlyfocaldyads = TRUE, limit2focalnonfocal = FALSE )
b.source |
data frame with behavioural data |
from |
character or date in format YYYY-MM-DD, by default the earliest and latest date in |
to |
character or date in format YYYY-MM-DD, by default the earliest and latest date in |
behaviours |
character string with codes of behaviours to be considered, by default all behaviours that occur in the data are considered. Can also be a named list if merging of different codes into broader categories is desired (see details). |
ot.source |
data frame with observation time data |
ot.type |
eiter |
duration.NA.treatm |
by default |
presence |
optional data.frame in the form of date by ID, with 0 and 1 indicating whether an ID was present on a given day or not; first column must be a date (YYYY-MM-DD); see |
directed |
logical, if actors and receivers are differentiated, a directed CSI is returned, i.e. with each dyad represented twice (once in each direction within the dyad) |
onlyfocaldyads |
logical, |
limit2focalnonfocal |
logical, |
Typically, behaviours to be considered are supplied in the form behaviours=c("groom", "approach")
. If you wish to merge behaviours into broader categories, supply a named list, e.g. list(groom=c("grm.received", "grm.given"), greet=c("greet", "mount", "grunt"))
. In such a case, behaviours in a given category are summed first to calculate the rates with which the behaviour categories occur.
a data.frame with DSI and standardized DSI. For the latter, the rates of behaviours are z-transformed before they are summed and divided by the number of behaviours.
Silk, J. B., Altmann, J., & Alberts, S. C. (2006). Social relationships among adult female baboons (Papio cynocephalus) I. Variation in the strength of social bonds.Behavioral Ecology and Sociobiology,61(2), 183–195. https://doi.org/10.1007/s00265-006-0249-2 Silk, J. B., Cheney, D. L., & Seyfarth, R. M. (2013). A practical guide to the study of social relationships. Evolutionary Anthropology,22(5), 213–225. https://doi.org/10.1002/evan.21367
## Not run: data(dataset3) DSI(dataset3$dataseq, presence = dataset3$presence) DSI(dataset3$dataseq) data(dataset3) DSI(dataset3$dataseq, onlyfocaldyads=TRUE, limit2focalnonfocal = FALSE) #default DSI(dataset3$dataseq, onlyfocaldyads=FALSE, limit2focalnonfocal = FALSE) DSI(dataset3$dataseq, onlyfocaldyads=FALSE, limit2focalnonfocal = TRUE) DSI(dataset3$dataseq, onlyfocaldyads=TRUE, limit2focalnonfocal = TRUE) DSI(dataset3$dataseq, onlyfocaldyads=TRUE, limit2focalnonfocal = FALSE, presence=dataset3$presence) DSI(dataset3$dataseq, onlyfocaldyads=FALSE, limit2focalnonfocal = FALSE, presence=dataset3$presence) DSI(dataset3$dataseq, onlyfocaldyads=FALSE, limit2focalnonfocal = TRUE, presence=dataset3$presence) DSI(dataset3$dataseq, onlyfocaldyads=TRUE, limit2focalnonfocal = TRUE, presence=dataset3$presence) DSI(dataset3$dataseq, ot.source=dataset3$ot, onlyfocaldyads=TRUE, limit2focalnonfocal = FALSE, presence=dataset3$presence) DSI(dataset3$dataseq, ot.source=dataset3$ot, onlyfocaldyads=FALSE, limit2focalnonfocal = FALSE, presence=dataset3$presence) DSI(dataset3$dataseq, ot.source=dataset3$ot, onlyfocaldyads=FALSE, limit2focalnonfocal = TRUE, presence=dataset3$presence) DSI(dataset3$dataseq, ot.source=dataset3$ot, onlyfocaldyads=TRUE, limit2focalnonfocal = TRUE, presence=dataset3$presence) ## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.