dominates {socialranking} | R Documentation |
Dominance
Description
Check if one element dominates the other.
Usage
dominates(powerRelation, e1, e2, strictly = FALSE, includeEmptySet = TRUE)
Arguments
powerRelation |
A |
e1 , e2 |
Elements in |
strictly |
If |
includeEmptySet |
If |
Details
is said to dominate
if
for all
.
strictly dominates
if there also exists an
such that
.
Value
Logical value TRUE
if e1
dominates e2
, else FALSE
.
Examples
pr <- as.PowerRelation("12 > 1 > 2")
# TRUE
d1 <- dominates(pr, 1, 2)
# FALSE
d2 <- dominates(pr, 2, 1)
# TRUE (because it's not strict dominance)
d3 <- dominates(pr, 1, 1)
# FALSE
d4 <- dominates(pr, 1, 1, strictly = TRUE)
stopifnot(all(d1, !d2, d3, !d4))
[Package socialranking version 1.2.0 Index]