ggOneToOne | R Documentation |
This function is a wrapper around ggplot geom_point to allow for plotting one-to-one sample comparisons in ArchR.
ggOneToOne(
x = NULL,
y = NULL,
size = 2,
alpha = 1,
xlabel = "x",
ylabel = "y",
title = "Correlation",
min = 0.05,
max = 0.9999,
nPlot = 100 * 10^3,
nKernel = 100,
densityMax = 0.95,
extend = 0.05,
baseSize = 6,
rastr = TRUE,
pal = paletteContinuous(set = "blueYellow"),
...
)
x |
A numeric vector containing the x-axis values for each point. |
y |
A numeric vector containing the y-axis values for each point. |
size |
The numeric size of the points to plot. |
alpha |
A number indicating the transparency to use for each point. See |
xlabel |
The label to plot for the x-axis. |
ylabel |
The label to plot for the y-axis. |
title |
The title of the plot. |
min |
The lower limit of the x and y axes as a numeric quantile between 0 and 1. |
max |
The upper limit of the x and y axes as a numeric quantile between 0 and 1. |
nPlot |
The number of points to plot. When this value is less than the total points, the |
nKernel |
The number of grid points in each direction to use when computing the kernel with |
densityMax |
The quantile that should be represented by the maximum color on the continuous scale designated by |
extend |
A numeric value indicating the fraction to extend the x-axis and y-axis beyond the maximum value on either axis. For example, 0.05 will extend the x-axis and y-axis by 5 percent on each end beyond |
baseSize |
The base font size (in points) to use in the plot. |
rastr |
A boolean value that indicates whether the plot should be rasterized. This does not rasterize lines and labels, just the internal portions of the plot. |
pal |
A custom palette from |
... |
Additional params to be supplied to ggPoint |
# Create Random Data
m <- data.frame(matrix(rnorm(20, 2),ncol=2))
# Plot
p <- ggOneToOne(x = m[,1], y = m[,2])
# To PDF
pdf("test.pdf", width = 4, height = 4)
p
dev.off()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.