submit_model: S3 generic method for submit_model

Description Usage Arguments Value

View source: R/submit-model.R

Description

S3 generic method for submit_model

S3 dispatch for submit_model from bbi_nonmem_model

S3 dispatch for submit_model from character scaler. Should be path to yaml (with or without .yaml extension), or a valid model file (control stream, etc.).

S3 dispatch for submit_model from numeric input This will only work if you are calling from the same directory as the models, or if you have set the model directory with 'set_model_directory()'

Submit a NONMEM model via babylon

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
submit_model(
  .mod,
  .bbi_args = NULL,
  .mode = c("sge", "local"),
  ...,
  .config_path = file.path(get_model_directory() %||% ".", "babylon.yaml"),
  .wait = TRUE,
  .dry_run = FALSE,
  .directory = NULL
)

## S3 method for class 'bbi_nonmem_model'
submit_model(
  .mod,
  .bbi_args = NULL,
  .mode = c("sge", "local"),
  ...,
  .config_path = file.path(get_model_directory() %||% ".", "babylon.yaml"),
  .wait = TRUE,
  .dry_run = FALSE,
  .directory = NULL
)

## S3 method for class 'character'
submit_model(
  .mod,
  .bbi_args = NULL,
  .mode = c("sge", "local"),
  ...,
  .config_path = file.path(get_model_directory() %||% ".", "babylon.yaml"),
  .wait = TRUE,
  .dry_run = FALSE,
  .directory = get_model_directory()
)

## S3 method for class 'numeric'
submit_model(
  .mod,
  .bbi_args = NULL,
  .mode = c("sge", "local"),
  ...,
  .config_path = file.path(get_model_directory() %||% ".", "babylon.yaml"),
  .wait = TRUE,
  .dry_run = FALSE,
  .directory = get_model_directory()
)

submit_nonmem_model(
  .mod,
  .bbi_args = NULL,
  .mode = c("sge", "local"),
  ...,
  .config_path = file.path(get_model_directory() %||% ".", "babylon.yaml"),
  .wait = TRUE,
  .dry_run = FALSE
)

Arguments

.mod

An S3 object of class 'bbi_nonmem_model', for example from 'new_model()', 'read_model()' or 'copy_model_from()'

.bbi_args

A named list specifying arguments to pass to babylon formatted like 'list("nm_version" = "nm74gf_nmfe", "json" = T, "threads" = 4)'. Run 'print_nonmem_args()' to see valid arguments.

.mode

Either "local" for local execution or "sge" to submit model(s) to the grid

...

args passed through to 'bbi_exec()'

.config_path

Optionally specify a path to a babylon.yml config. If not specified, the config in the model directory will be used by default. Path MUST be either an absolute path or relative to the model directory.

.wait

Boolean for whether to wait for the bbi process to return before this function call returns.

.dry_run

Returns an object detailing the command that would be run, insted of running it. This is primarily for testing but also a debugging tool.

.directory

Model directory containing the files referenced by ‘.mod'. Defaults to 'options(’rbabylon.model_directory')', which can be set globally with 'set_model_directory()'.

Value

An S3 object of class 'babylon_process'


metrumresearchgroup/mrgvalidatetestreference documentation built on Aug. 15, 2021, 8:13 a.m.