plot_parameters_distributions: Individual parameters distributions

View source: R/plot_parameters_distributions.R

plot_parameters_distributionsR Documentation

Individual parameters distributions

Description

Plots the distributions of the selected individual parameters.

Usage

plot_parameters_distributions(
  run,
  parameters = NULL,
  baseline_only = TRUE,
  type = "histogram",
  histogram_bins = 30L,
  histogram_empirical_density = FALSE,
  histogram_reference_distribution = list(fun = dnorm, args = list(mean = 0, sd = 1)),
  qq_reference_distribution = list(fun = qnorm, args = list(mean = 0, sd = 1)),
  boxplot_facets = TRUE,
  boxplot_drop_unused = FALSE,
  facet_scales = "free",
  overlay_splits = TRUE,
  auto_legend = TRUE
)

Arguments

run

pmxploit NONMEM run object.

parameters

character vector of parameters names. Default is NULL, returning all individual parameters (random and post-hoc).

baseline_only

logical. Consider only the baseline (= first) values of the subjects. Default is TRUE.

type

character. Type of distribution representation. One of histogram, density, boxplot and qq (Q-Q plot of the Normal distribution). Default is histogram.

histogram_bins

integer. If type = "histogram", sets the number of bins. Default is 30.

boxplot_facets

logical. If type = "boxplot", represent boxplots in different facets when TRUE.

boxplot_drop_unused

logical. If type = "boxplot", drops unused factor levels when TRUE.

facet_scales

character. ggplot2 facet scales. Default is "free".

overlay_splits

logical. If splitting is applied, TRUE will overlay splits on a same graph while FALSE will plot them on different facets. Default is TRUE.

auto_legend

logical. When TRUE (default), default pmxploit plotting options are applied (title, labels, axis...).

Value

A ggplot2 object.

Examples

EXAMPLERUN %>% plot_parameters_distributions()
EXAMPLERUN %>% plot_parameters_distributions(type = "density")
EXAMPLERUN %>% plot_parameters_distributions(type = "boxplot")
EXAMPLERUN %>% plot_parameters_distributions(type = "qq")

EXAMPLERUN %>% plot_parameters_distributions(parameters = "eta")

EXAMPLERUN %>%
  plot_parameters_distributions(parameters = "ETCL",
                                histogram_empirical_density = TRUE,
                                histogram_reference_distribution = list(fun = dnorm,
                                                                        args = list(mean = 0, sd = 1)))

pnolain/pmxploit documentation built on Jan. 31, 2024, 1:16 p.m.