score: Solution score

View source: R/generics.R

scoreR Documentation

Solution score

Description

Extract solution score from RapResults() or RapSolved() object.

Usage

score(x, y)

## S3 method for class 'RapResults'
score(x, y = 0)

## S3 method for class 'RapSolved'
score(x, y = 0)

Arguments

x

RapResults() or RapSolved() object.

y

Available inputs include: NULL to return all scores, integer number specifying the solution for which the score should be returned, and 0 to return score for the best solution.

Value

matrix or numeric vector with solution score(s) depending on arguments.

See Also

RapResults(), RapSolved().

Examples

## Not run: 
# load data
data(sim_rs)

# score for the best solution
score(sim_rs, 0)

# score for the second solution
score(sim_rs, 2)

# score for all solutions
score(sim_rs, NULL)

## End(Not run)

raptr documentation built on March 31, 2023, 9:46 p.m.