perm.double.grp.single {ANTs}R Documentation

Double permutation approach for gambit of the group

Description

Double permutation approach for gambit of the group

Usage

perm.double.grp.single(
  obs,
  scan,
  ctrlf,
  nperm,
  progress = TRUE,
  index = "sri",
  measure,
  test = "median",
  df = NULL,
  dfid = NULL,
  ...
)

Arguments

obs

a data frame of gambit of the group observations. The data frame must have a column named 'ID'.

scan

an integer indicating the column of scans of individual associations in obs.

ctrlf

A confounding factor by which to control group associationsin obs.

nperm

number of permutations to perform.

progress

a boolean indicating if the permutation process must be visible.

index

Which type of index of associations to calculate:

  • 'sri' for Simple ratio index: x \div x+yAB+yA+yB

  • 'hw' for Half-weight index: x/x+yAB+1/2(yA+yB)

  • 'sr' for Square root index:x/sqr((x+yAB+yA)(x+yAB+yB))

measure

a character indicating the social network measure to compute (Only those available in ANTs)

test

a character indicating the test to realize to account for the social network measure

df

a data frame of individual characteristics in which store permutations.

dfid

an integer or a string indicating the column with individual ids in argument df.

...

Additional arguments related to the social network measure to compute (argument measure).

Details

Output need to be incorporated in a data frame and node label permutations with ANTs function perm.net.nl need to be performed before using any ANTs functions "stat.".

Value

A numeric vector of individuals social measure corrected by double permutation approch (node label permutation can the be perfomed on this output)

References

Farine, D. R., & Carter, G. G. (2022). Permutation tests for hypothesis testing with animal social network data: Problems and potential solutions. Methods in Ecology and Evolution, 13, 144- 156. https://doi.org/10.1111/2041-210X.13741


[Package ANTs version 0.0.16 Index]