Description Usage Arguments Details Value Author(s) References Examples
Calculates Average Dominance Index.
1 |
data_sheet |
either a data.frame f.e imported from a data sheet containing |
bytes |
a string where each enabled action is set to 1 and each disabled action is set to 0 |
... |
Additional parameters:
|
Calculates Average Dominance Index.
returns a list with
ADI - the Average Dominance index
Colors - the colors supported by vcolors sorted by ADI of the items
ADI_count_matrix - the counts from which the ADI was calculated
Knut Krueger, Knut.Krueger@equine-science.de
The Construction of Dominance Order: Comparing Performance of Five Methods Using an Individual-Based Model C. K. Hemelrijk, J. Wantia and L. Gygax, Behaviour Vol. 142, No. 8 (Aug., 2005), pp. 1037-1058
doi: 10.1163/156853905774405290
On using the DomWorld model to evaluate dominance ranking methods , de Vries, Han, Behaviour, Volume 146, Number 6, 2009 , pp. 843-869(27)
doi: 10.1163/156853909X412241
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 | { #you can eihter use:
data_sheet=data.frame ("action.from"=c(1,4,2,3,4,3,4,3,4,3,4,3,4,3,4),
"action.to"=c(4,1,1,4,3,4,3,4,3,4,3,4,3,4,3),
"kind.of.action"= c(4,1,1,4,3,4,3,4,3,4,3,4,3,4,3),stringsAsFactors=FALSE)
items= data.frame ("Name"=c("item1","item2","item3","item4","item5","item6") ,
"item.number"=c(1:6),stringsAsFactors=FALSE)
actions=data.frame("name.of.action"= c("leading","following","approach","bite","threat to bite",
"kick","threat to kick", "chase","retreat"),
"action.number"=c(1:9),
"classification"=c(1,2,1,1,1,1,1,1,2) ,
"weighting"=c(1,-1,1,1,1,1,1,1,-1),stringsAsFactors=FALSE)
#all encounters without leading and following
bytes= "001111111"
ADI(data_sheet,items=items,actions=actions,bytes)
# or you can use a complete f.e Excel sheet
# you can save this data as basic excel sheet to work with
data(data_ADI)
bytes= "001111111"
ADI(data_ADI,bytes)
}
|
OpenJDK 64-Bit Server VM warning: Can't detect initial thread stack location - find_vma failed
$ADI
Pferd2 Pferd3 Pferd1 Pferd4 Pferd5 Pferd6 results.ADI id rank
Pferd2 NA NaN 1 NaN NaN NaN 1.00000000 2 1
Pferd3 NaN NA NaN 0.9166667 NaN NaN 0.91666667 3 2
Pferd1 0 NaN NA 1.0000000 NaN NaN 0.50000000 1 3
Pferd4 NaN 0.08333333 0 NA NaN NaN 0.04166667 4 4
Pferd5 NaN NaN NaN NaN NA NaN 0.00000000 5 5
Pferd6 NaN NaN NaN NaN NaN NA 0.00000000 6 6
$Colors
[1] ""
$ADI_count_matrix
Pferd1 Pferd2 Pferd3 Pferd4 Pferd5 Pferd6
Pferd1 NA 0 0 2 0 0
Pferd2 1 NA 0 0 0 0
Pferd3 0 0 NA 11 0 0
Pferd4 0 0 1 NA 0 0
Pferd5 0 0 0 0 NA 0
Pferd6 0 0 0 0 0 NA
Warning message:
system call failed: Cannot allocate memory
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.