Learn R Programming

rorutadis (version 0.4.2)

addAssignmentPairwiseAtMostComparisons: Add assignment pairwise at most comparisons

Description

The comparison of a pair of alternatives may indicate that alternative a_i should be assigned to a class at most better by k classes then class of a_j. The function assignmentPairwiseAtMostComparisons allows to define such pairwise comparisons.

Usage

addAssignmentPairwiseAtMostComparisons(problem, ...)

Arguments

problem
Problem to which preference information will be added.
...
Comparisons as three-element vectors. Each vector c(i, j, k) represents a single assignment comparison: alternative a_i has to be assigned to class at most better by k classes then class of a_j.

Value

Problem with added comparisons.

See Also

buildProblem removeAssignmentPairwiseAtMostComparisons

Examples

Run this code
# 4 alternatives, 2 gain criteria, 3 classes, monotonously increasing
# and general marginal value functions
perf <- matrix(c(5, 2, 1, 7, 0.5, 0.9, 0.4, 0.4), ncol = 2)
problem <- buildProblem(perf, 3, FALSE, c('g', 'g'), c(0, 0))

# add comparison:
# alternative 4 to class at most better by 1 class then class
# of alternative 3
problem <- addAssignmentPairwiseAtMostComparisons(problem, c(4, 3, 1))

Run the code above in your browser using DataLab