Returns the pairs of instance IDs and seeds used as instances in the race (and optionally the actual instances).
Source:R/parameterAnalysis.R
get_instanceID_seed_pairs.Rd
Returns the pairs of instance IDs and seeds used as instances in the race (and optionally the actual instances).
Arguments
- iraceResults
(
list()
|character(1)
)
Object created by irace and typically saved in the log fileirace.Rdata
. If a character string is given, then it is interpreted as the path to the log file from which theiraceResults
object will be loaded.- index
(
integer()
)
Indexes of the (instanceID,seed) pairs to be returned. The default returns everything.- instances
(
logical(1)
)
Whether to add the actual instances as an additional column (only if the instances are of atomic type).
Value
With default arguments, a data frame containing two columns
"instanceID"
and "seed"
. With instances=TRUE
and if the instances
are of atomic type (see is.atomic()
) type, another column instance
is
added that contains the actual instance.
Examples
log_file <- system.file("exdata/irace-acotsp.Rdata", package="irace", mustWork=TRUE)
head(get_instanceID_seed_pairs(log_file))
#> instanceID seed
#> 1 7 2062824562
#> 2 1 1315404608
#> 3 9 718135261
#> 4 8 1756600186
#> 5 2 1084471193
#> 6 10 1163321042
# Add the instance names
get_instanceID_seed_pairs(log_file, index=1:10, instances=TRUE)
#> instanceID seed instance
#> 1 7 2062824562 ./instances/1000-7.tsp
#> 2 1 1315404608 ./instances/1000-1.tsp
#> 3 9 718135261 ./instances/1000-9.tsp
#> 4 8 1756600186 ./instances/1000-8.tsp
#> 5 2 1084471193 ./instances/1000-2.tsp
#> 6 10 1163321042 ./instances/1000-10.tsp
#> 7 3 1318942249 ./instances/1000-3.tsp
#> 8 4 424612740 ./instances/1000-4.tsp
#> 9 6 507331628 ./instances/1000-6.tsp
#> 10 5 1640400685 ./instances/1000-5.tsp