R/filenames.R

Defines functions getProblemFilePaths getAlgorithmFilePath

getAlgorithmFilePath = function(file.dir, id) {
  # fix for case-insensitive file names
  id = gsub("([[:upper:]])", "@\\1", id)
  file.path(file.dir, "algorithms", sprintf("%s.RData", id))
}

getProblemFilePaths = function(file.dir, id) {
  # fix for case-insensitive file names
  id = gsub("([[:upper:]])", "@\\1", id)
  parts = c("static", "dynamic")
  setNames(file.path(file.dir, "problems", sprintf("%s_%s.RData", id, parts)), parts)
}

Try the BatchExperiments package in your browser

Any scripts or data that you put into this service are public.

BatchExperiments documentation built on March 21, 2022, 5:06 p.m.