PlotDoseResponseCurve: Plot Dose Response Curve for Single Drug

Description Usage Arguments Value Author(s) Examples

View source: R/plot_dose_response_curve.R

Description

This function will pot the dose response curve fitted by 4 parameters log-logistic curve.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
PlotDoseResponseCurve(
  data,
  plot_block = 1,
  drug_index = 1,
  adjusted = TRUE,
  Emin = NA,
  Emax = NA,
  grid = expression(graphics::grid(col = "#DFDFDF", lty = 1)),
  point_color = "#C24B40",
  curve_color = "black",
  text_size_scale = 1,
  plot_title = NULL,
  plot_subtitle = NULL,
  plot_setting = list(cex.lab = 1 * text_size_scale, mgp = c(2, 0.5, 0), font.main = 2,
    font.lab = 3, cex.main = 14/12 * text_size_scale, bty = "l", lwd = 1.5),
  plot_new = TRUE,
  record_plot = TRUE
)

Arguments

data

A list object generated by function ReshapeData.

plot_block

A character/integer. It indicates the block ID for the block to visualize.

drug_index

A character/integer. It indicates the index of the drug to plot. For example, 1 or "1" indicates to plot "drug1" in the input data.

adjusted

A logical value. If it is FALSE, original response value will be used to fit the curve. If it is TRUE, the response values adjusted by (adding noise and/or imputation) will be plotted.

Emin

A numeric or NA. the minimal effect of the drug used in the 4-parameter log-logistic function to fit the dose-response curve. If it is not NA, it is fixed the value assigned by the user. Default setting is NA.

Emax

A numeric or NA. the maximal effect of the drug used in the 4-parameter log-logistic function to fit the dose-response curve. If it is not NA, it is fixed the value assigned by the user. Default setting is NA.

grid

A expression for grid function of NULL. If it is NULL, no grids will be shown in the plot.

point_color

An R color value. It indicates the color for points in dose response curve plots.

curve_color

An R color value. It indicates the color for curves in dose response curve plots.

text_size_scale

A numeric value. It is used to control the size of text in the plot. All the text size will multiply by this scale factor.

plot_title

A character value or NULL. It specifies the plot title. If it is NULL, the function will automatically generate a title.

plot_subtitle

A character or NULL. It indicates the subtitle for the plot. If it is NULL, the function will automatically generate a subtitle.

plot_setting

A list of graphical arguments. The arguments are passed to par function to modify the appearance of plots.

plot_new

A logic value. If it is TRUE, a new device will be initiate with plot.new. You might want to set it as FALSE while combining with other plots by using layout function.

record_plot

A logic value. If it is TRUE, a plot object recorded by recordPlot will be returned. If it is FALSE, this function will return NULL.

Value

A plot object recorded by recordPlot or NULL.

Author(s)

Examples

1
2
3
4

synergyfinder documentation built on April 4, 2021, 6 p.m.