Skip to contents

Selectively clears the based_on, copied_from, and/or tags fields in the metadata file associated with a model. Fields not selected are left unchanged.

Usage

clear_metadata_file(
  model_path,
  based_on = FALSE,
  copied_from = FALSE,
  tags = FALSE
)

Arguments

model_path

Path to the NONMEM model file, or a hyperion_nonmem_model object

based_on

If TRUE, clear the based_on field. Default FALSE.

copied_from

If TRUE, clear the copied_from field. Default FALSE.

tags

If TRUE, clear the tags field. Default FALSE.

Value

The model's updated metadata, as returned by get_model_metadata()

Examples

if (FALSE) { # \dontrun{
clear_metadata_file("model/nonmem/run001.mod", tags = TRUE)
model <- read_model("model/nonmem/run001.mod")
clear_metadata_file(model, based_on = TRUE, copied_from = TRUE)
} # }