plot_SynergyLMM: Plotting SynergyLMM results

View source: R/plot_SynergyLMM.R

plot_SynergyLMMR Documentation

Plotting SynergyLMM results

Description

Generic function to generate different types of plots based on SynergyLMM outputs.

Usage

plot_SynergyLMM(object, plot_type = "lmmModel", ...)

Arguments

object

An object generated by lmmModel() or lmmSynergy() functions.

plot_type

String indicating the type of plot to generate. Possible options include:

  • "lmmModel" for plotting of tumor growth data from a fitted model.

  • "lmmSynergy" for plotting synergy results.

  • "ObsvsPred" for generating plots of Observed vs Predicted Values.

  • "ranefDiagnostics" for plots of random effects diagnostics.

  • "residDiagnostics" for plots of residual diagnostics.

...

Additional arguments passed to the specific plot function.

Value

Different output plots are produced depending on the plot_type selected.

See Also

plot_lmmModel(), plot_lmmSynergy(), plot_ObsvsPred(), plot_ranefDiagnostics(), plot_residDiagnostics().

Examples

data(grwth_data)
# Fit the model
lmm <- lmmModel(
  data = grwth_data,
  sample_id = "subject",
  time = "Time",
  treatment = "Treatment",
  tumor_vol = "TumorVolume",
  trt_control = "Control",
  drug_a = "DrugA",
  drug_b = "DrugB",
  combination = "Combination",
  show_plot = FALSE
  )
  
# Plot lmmModel
plot_SynergyLMM(lmm, plot_type = "lmmModel",
trt_control = "Control",
drug_a = "DrugA",
drug_b = "DrugB",
combination = "Combination"
)

# Plot ObsvsPred
plot_SynergyLMM(lmm, plot_type = "ObsvsPred")

# Plot ranefDiagnostics
plot_SynergyLMM(lmm, plot_type = "ranefDiagnostics")

# Plot residDiagnostics
plot_SynergyLMM(lmm, plot_type = "residDiagnostics")

# Plot lmmSynergy
lmmSyn <- lmmSynergy(lmm)
plot_SynergyLMM(lmmSyn, plot_type = "lmmSynergy")

SynergyLMM documentation built on April 4, 2025, 4:13 a.m.