Description Usage Arguments Value
Partition of variation within- and among-individuals following the method summarised by Van de Pol & Wright (2009) (doi: 10.1016/j.anbehav.2008.11.006)
1 | d_centering(data, centering_by, cluster = NULL, variable)
|
data |
data frame |
centering_by |
individual ID |
cluster |
higher level structure. E.g. levels in centering_by further structured in cluster. NULL as default |
variable |
character name or vector of characters. Variables to be partitioned.If more than one,please, concatenate using 'c'. |
New variables added to the end of the original data frame with 'mean_' prefix for the mean value of variable for every centering_by level and prefix 'cent' for the within-indivual term.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.