Learn R Programming

NMproject (version 0.6.9)

output_table: Reads all $TABLE outputs and merge with input dataset

Description

[Stable]

Produces a single merged output dataset will all columns of $INPUT dataset. This is useful for reuse of exploratory data plots as diagnostic plots as all columns including text columns used for ggplot facetting will be present.

Usage

output_table(r, only_append = c(), ...)

output_table_first(r, ...)

Value

A list of tibbles with merged version of all output $TABLEs and the input data. Additional columns will be INNONMEM which will be TRUE for rows that were not ignored by NONMEM. For simulation control files there is also DV_OUT which will contain simulated DV values. DV will always be unmodified from the input dataset.

output_table_first will return a tibble with a single run.

Arguments

r

An object of class nm.

only_append

Optional character vector. If missing will append all, otherwise will append only those variables requested.

...

Optional additional arguments to pass on to read.csv of orig data.

See Also

nm_render(), input_data()

Examples

Run this code

## requires NONMEM to be installed

if (FALSE) {

## exploratory data plot
read_derived_data("DerivedData/data.csv") %>%
  ggplot(aes(x = TIME, y = DV)) +
  theme_bw() +
  geom_point() +
  geom_line(aes(group = ID)) +
  facet_wrap(~STUDYTXT)

m1 %>%
  output_table_first() %>%
  ggplot(aes(x = TIME, y = DV)) +
  theme_bw() +
  geom_point() +
  geom_line(aes(group = ID)) +
  facet_wrap(~STUDYTXT) +
  ## additional layer for overlaying IPRED curves
  geom_line(aes(y = IPRED, group = ID))
}

Run the code above in your browser using DataLab