View source: R/snp_utils_plot.R
hallgrimskirkja_plot | R Documentation |
Title
hallgrimskirkja_plot(
df,
left_slop,
right_slop,
left_bins_num = 50,
centre_bins_num = 50,
right_bins_num = 25,
facet_regions = F,
legend_position = c(0.94, 0.7),
fill_by = c("region", "event", "bin", "count"),
x_labels = c("exon", "generic", "bins"),
event_type = NULL
)
df |
|
left_slop |
A number defining how much you slopped the bed file upstream (strand aware). |
right_slop |
A number defining how much you slopped the bed file downstream (strand aware). |
left_bins_num |
Number of bins you used for binning the upstream region. |
centre_bins_num |
Number of bins you used for binning the central region(s). |
right_bins_num |
Number of bins you used for binning the downstream region. |
facet_regions |
Logical defining whether to slightly separate (facet) the individual regions. Can be either |
legend_position |
Where to put the legend. Goes to |
fill_by |
How to colour the histogram, one of |
x_labels |
How to label the X-axis text, still not perfect. |
event_type |
Text to put in the title. |
The parameter fill_by
defines how to colour the plot: region
colours by the type of region, meaning upstream, centre or downstream region.
event
colours by the number of events (i.e. exons) with an SNP in that specific bin. It serves to check that high bars are due to many different event regions and not one single hot spot in few events.
bin
colours by the bin number in each region and count
fills based on how tall is the bar in the histogram.
A ggplot
save the plots with ggsave( device = cairo_pdf) and not with device = 'pdf'.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.