- modification_locations
character vector. One character value for each sequence, storing a condensed string (e.g. "3,6,9,12", produced via vector_to_string()) of the indices along the read at which modification was assessed. Indexing starts at 1.
- modification_probabilities
character vector. One character value for each sequence, storing a condensed string (e.g. "0,128,255,15", produced via vector_to_string()) of the probability of methylation/modification at each assessed base.
Assumed to be Nanopore > SAM style modification stored as an 8-bit integer from 0 to 255, but changing other arguments could make this work on other scales.
- sequence_lengths
numeric vector. The length of each sequence.
- low_colour
character. The colour that should be used to represent minimum probability of methylation/modification (defaults to blue).
- high_colour
character. The colour that should be used to represent maximum probability of methylation/modification (defaults to red).
- low_clamp
numeric. The minimum probability below which all values are coloured low_colour. Defaults to 0 (i.e. no clamping). To specify a proportion probability in 8-bit form, multiply by 255 e.g. to low-clamp at 30% probability, set this to 0.3*255.
- high_clamp
numeric. The maximum probability above which all values are coloured high_colour. Defaults to 255 (i.e. no clamping, assuming Nanopore > SAM style modification calling where probabilities are 8-bit integers from 0 to 255).
- background_colour
character. The colour the background should be drawn (defaults to white).
- other_bases_colour
character. The colour non-assessed (e.g. non-CpG) bases should be drawn (defaults to grey).
- outline_colour
character. The colour of the box outlines. Defaults to black.
- outline_linewidth
numeric. The linewidth of the box outlines. Defaults to 3. Set to 0 to disable box outlines.
- outline_join
character. One of "mitre", "round", or "bevel" specifying how outlines should be joined at the corners of boxes. Defaults to "mitre". It would be unusual to need to change this.
- modified_bases_outline_colour
character. If NA (default), inherits from outline_colour. If not NA, overrides outline_colour for modification-assessed bases only.
- modified_bases_outline_linewidth
numeric. If NA (default), inherits from outline_linewidth. If not NA, overrides outline_linewidth for modification-assessed bases only.
- modified_bases_outline_join
character. If NA (default), inherits from outline_join. If not NA, overrides outline_join for modification-assessed bases only.
- other_bases_outline_colour
character. If NA (default), inherits from outline_colour. If not NA, overrides outline_colour for non-modification-assessed bases only.
- other_bases_outline_linewidth
numeric. If NA (default), inherits from outline_linewidth. If not NA, overrides outline_linewidth for non-modification-assessed bases only.
- other_bases_outline_join
character. If NA (default), inherits from outline_join. If not NA, overrides outline_join for non-modification-assessed bases only.
- margin
numeric. The size of the margin relative to the size of each base square. Defaults to 0.5 (half the side length of each base square).
- return
logical. Boolean specifying whether this function should return the ggplot object, otherwise it will return invisible(NULL). Defaults to TRUE.
- filename
character. Filename to which output should be saved. If set to NA (default), no file will be saved. Recommended to end with ".png", but can change if render device is changed.
- render_device
function/character. Device to use when rendering. See ggplot2::ggsave() documentation for options. Defaults to ragg::agg_png. Can be set to NULL to infer from file extension, but results may vary between systems.
- pixels_per_base
integer. How large each box should be in pixels, if file output is turned on via setting filename. Corresponds to dpi of the exported image. Defaults to 20. Low values acceptable as currently this function does not write any text.