covBars {GenVisR} | R Documentation

## Construct an overall coverage cohort plot

### Description

Given a matrix construct a plot to display sequencing depth acheived as percentage bars for a cohort of samples.

### Usage

    covBars(
      x,
      colour = NULL,
      plot_title = NULL,
      x_title_size = 12,
      y_title_size = 12,
      facet_lab_size = 10,
      plotLayer = NULL,
      out = "plot"
    )

### Arguments

`x` | Object of class matrix with rows representing the sequencing depth (i.e. number of reads) and columns corresponding to each sample in the cohort and elements of the matrix
`colour` | Character vector specifying colours to represent sequencing depth.
`plot_title` | Character string specifying the title to display on the plot.
`x_title_size` | Integer specifying the size of the x-axis title.
`y_title_size` | Integer specifying the size of the y-axis title.
`facet_lab_size` | Integer specifying the size of the faceted labels plotted.
`plotLayer` | Valid ggplot2 layer to be added to the plot.
`out` | Character vector specifying the the object to output, one of "data", "grob", or "plot", defaults to "plot" (see returns).

### Value

One of the following, a list of dataframes containing data to be plotted, a grob object, or a plot.

### Examples

    # Create data
    x <- matrix(sample(100000,500), nrow=50, ncol=10, dimnames=list(0:49,paste0("Sample",1:10)))

    # Call plot function
    covBars(x)

[Package GenVisR version 1.19.6 Index]