View source: R/pmx-plots-scatter.R
residual_scatter | R Documentation |
Scatter residual plots
DV vs PRED plot
DV vs IPRED plot
IWRES vs IPRED plot
|IWRES| vs IPRED plot
|IWRES| vs TIME plot
IWRES vs TIME plot
NPDE vs TIME plot
NPDE vs PRED plot
NPD vs TIME plot
NPD vs EPRED plot
NPD vs PRED plot
CWRES vs TIME plot
CWRES vs CPRED plot
CWRES vs PRED plot
residual_scatter(
sim_blq,
point,
is.hline,
hline,
dname,
bloq,
filter,
strat.facet,
facets,
strat.color,
trans,
pmxgpar,
labels,
axis.title,
axis.text,
ranges,
is.smooth,
smooth,
is.band,
band,
is.draft,
draft,
is.identity_line,
identity_line,
scale_x_log10,
scale_y_log10,
color.scales,
...
)
pmx_plot_dv_pred(ctr, ...)
pmx_plot_dv_ipred(ctr, ...)
pmx_plot_iwres_ipred(ctr, ...)
pmx_plot_abs_iwres_ipred(ctr, ...)
pmx_plot_abs_iwres_time(ctr, ...)
pmx_plot_iwres_time(ctr, ...)
pmx_plot_npde_time(ctr, ...)
pmx_plot_npde_pred(ctr, ...)
pmx_plot_npd_time(ctr, ...)
pmx_plot_npd_epred(ctr, ...)
pmx_plot_npd_pred(ctr, ...)
pmx_plot_cwres_time(ctr, ...)
pmx_plot_cwres_cpred(ctr, ...)
pmx_plot_cwres_pred(ctr, ...)
sim_blq |
|
point |
|
is.hline |
|
hline |
|
dname |
|
bloq |
pmx_update parameters |
filter |
|
strat.facet |
|
facets |
|
strat.color |
|
trans |
|
pmxgpar |
a object of class pmx_gpar possibly the output of the pmx_gpar: Shared basic graphics parameters |
labels |
|
axis.title |
|
axis.text |
|
ranges |
|
is.smooth |
|
smooth |
|
is.band |
|
band |
|
is.draft |
|
draft |
|
is.identity_line |
|
identity_line |
|
scale_x_log10 |
|
scale_y_log10 |
|
color.scales |
|
... |
others graphics parameters passed :
residual parameters |
ctr |
pmx controller |
ggplot2 object
# NOTES ######################
# examples are availables for all residual plots:
# - pmx_plot_abs_iwres_ipred
# - pmx_plot_dv_ipred
# - pmx_plot_dv_pred
# - pmx_plot_iwres_ipred
# - pmx_plot_iwres_time
# - pmx_plot_npde_time
# basic use ---------------------------------------
ctr <- theophylline()
p <- ctr %>% pmx_plot_dv_pred()
## p is a ggplot2 object you can add any layer here
p + ggplot2::theme_minimal()
# update graphical parameter ----------------------
## update labels
ctr %>% pmx_plot_dv_pred(
labels = list(title = "DV versus PRED new title")
)
## remove draft
ctr %>% pmx_plot_dv_pred(is.draft = FALSE)
## remove horizontal line
ctr %>% pmx_plot_dv_pred(is.hline = FALSE)
## custom point aes and static parameters
## we can customize any geom_point parameter
ctr %>% pmx_plot_dv_pred(
point = list(aes(alpha = DV), color = "green", shape = 4)
)
# stratification ----------------------------------
## continuous stratification
ctr %>% pmx_plot_dv_pred(strat.color = ~WT0)
## categorical stratification
ctr %>% pmx_plot_dv_pred(strat.facet = ~SEX)
## using formula notation
ctr %>% pmx_plot_dv_pred(strat.facet = STUD~SEX)
# subsetting --------------------------------------
## we can use any expression involving the data
ctr %>% pmx_plot_dv_pred(filter = DV > mean(DV) & PRED < median(PRED))
## filter and stratify
ctr %>% pmx_plot_dv_pred(filter = SEX == 1, strat.facet = ~SEX)
# transformation --------------------------------------
## apply a log transformation in y
ctr %>% pmx_plot_dv_pred(trans = "log10_y")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.