Skip to contents

Merge Multiple Results

Usage

merge_results(obj, result_set, indices, id, ...)

Arguments

obj

The base object containing merge specifications

result_set

List of results to be merged

indices

List of indices corresponding to each result

id

Identifier for the merged result

...

Additional arguments passed to specific merge methods

Value

A merged result object containing:

  • Combined results from all input objects

  • Associated indices

  • Merged metadata

Examples

# \donttest{
ds <- gen_sample_dataset(D = c(5, 5, 5), nobs = 20, nlevels = 2)
model <- load_model("sda_notune")
mspec <- mvpa_model(
  model = model,
  dataset = ds$dataset,
  design = ds$design,
  model_type = "classification"
)
result_set <- tibble::tibble(
  result = list(NULL),
  error = FALSE,
  error_message = "~"
)
merge_results(mspec, result_set, indices = list(1:10), id = 1)
#> Warning: Unknown or uninitialised column: `test_ind`.
#> Warning: Unknown or uninitialised column: `probs`.
#> Error: length(observed) not equal to length(predicted)
# }