plot_sashimi {dasper} | R Documentation

## Visualise RNA-seq data in a the form of a sashimi plot

### Description

`plot_sashimi` plots the splicing events and coverage over a specific genes/transcript and/or genomic region of interest. The plotting are built from `ggplot2` functions.

### Usage

    plot_sashimi(
      junctions,
      ref,
      gene_tx_id,
      case_id = NULL,
      sum_func = mean,
      region = NULL,
      annot_colour = c(ggpubr::get_palette("jco", 1), ggpubr::get_palette("npg", 7)[c(1, 3,
        2, 5, 6)], ggpubr::get_palette("jco", 6)[c(3)]),
      digits = 2,
      count_label = TRUE
    )

### Arguments

`junctions` | junction data as a RangedSummarizedExperiment-class object.
`ref` | either path to gtf/gff3 or object of class TxDb-class.
`gene_tx_id` | gene name as ensembl id, ensembl transcript id or gene name.
`case_id` | list of one element. This must be a character vector containing the
`sum_func` | list of one element. This must be a character vector containing the
`region` | a GenomicRanges of length 1 that is used to filter the exons/junctions. Only those that overlap this region are plotted.
`annot_colour` | character vector of colours for junction types. One value must be supplied labelling each of the 7 possible types.
`digits` | used in `round`, specifying the number of digits to round the junction counts to for visualisation purposes.
`count_label` | logical value specifying whether to add label the count of each junction.

### Value

`ggplot` displaying the splicing (and coverage) surrounding the transcript/region of interest.

### Examples

    # use GenomicState to load txdb (GENCODE v31)
    ref <- GenomicState::GenomicStateHub(
        version = "31",
        genome = "hg38",
        filetype = "TxDb"
    )[[1]]

    junctions_processed <- junction_process(
        junctions_example,
        ref,
        types = c("ambig_gene", "unannotated")
    )

    sashimi_plot <- plot_sashimi(
        junctions = junction_filter(junctions_processed),
        ref = ref,
        gene_tx_id = "ENSG00000142156.14",
        sum_func = NULL
    )

[Package dasper version 1.2.0 Index]